mirror of
https://github.com/sigmasternchen/php-doc-en
synced 2025-03-15 16:38:54 +00:00

git-svn-id: https://svn.php.net/repository/phpdoc/en/trunk@334762 c90b9560-bf6c-de11-be94-00142212c4b1
106 lines
2.6 KiB
XML
106 lines
2.6 KiB
XML
<?xml version="1.0" encoding="utf-8"?>
|
|
<!-- $Revision$ -->
|
|
<refentry xmlns="http://docbook.org/ns/docbook" xml:id="function.ssh2-methods-negotiated">
|
|
<refnamediv>
|
|
<refname>ssh2_methods_negotiated</refname>
|
|
<refpurpose>Return list of negotiated methods</refpurpose>
|
|
</refnamediv>
|
|
|
|
<refsect1 role="description">
|
|
&reftitle.description;
|
|
<methodsynopsis>
|
|
<type>array</type><methodname>ssh2_methods_negotiated</methodname>
|
|
<methodparam><type>resource</type><parameter>session</parameter></methodparam>
|
|
</methodsynopsis>
|
|
<para>
|
|
Returns list of negotiated methods.
|
|
</para>
|
|
</refsect1>
|
|
|
|
<refsect1 role="parameters">
|
|
&reftitle.parameters;
|
|
<para>
|
|
<variablelist>
|
|
<varlistentry>
|
|
<term><parameter>session</parameter></term>
|
|
<listitem>
|
|
<para>
|
|
An SSH connection link identifier, obtained from a call to
|
|
<function>ssh2_connect</function>.
|
|
</para>
|
|
</listitem>
|
|
</varlistentry>
|
|
</variablelist>
|
|
</para>
|
|
</refsect1>
|
|
|
|
<refsect1 role="returnvalues">
|
|
&reftitle.returnvalues;
|
|
<para>
|
|
|
|
</para>
|
|
</refsect1>
|
|
|
|
<refsect1 role="examples">
|
|
&reftitle.examples;
|
|
<para>
|
|
<example>
|
|
<title>Determining what methods were negotiated</title>
|
|
<programlisting role="php">
|
|
<![CDATA[
|
|
<?php
|
|
$connection = ssh2_connect('shell.example.com', 22);
|
|
$methods = ssh2_methods_negotiated($connection);
|
|
|
|
echo "Encryption keys were negotiated using: {$methods['kex']}\n";
|
|
echo "Server identified using an {$methods['hostkey']} with ";
|
|
echo "fingerprint: " . ssh2_fingerprint($connection) . "\n";
|
|
|
|
echo "Client to Server packets will use methods:\n";
|
|
echo "\tCrypt: {$methods['client_to_server']['crypt']}\n";
|
|
echo "\tComp: {$methods['client_to_server']['comp']}\n";
|
|
echo "\tMAC: {$methods['client_to_server']['mac']}\n";
|
|
|
|
echo "Server to Client packets will use methods:\n";
|
|
echo "\tCrypt: {$methods['server_to_client']['crypt']}\n";
|
|
echo "\tComp: {$methods['server_to_client']['comp']}\n";
|
|
echo "\tMAC: {$methods['server_to_client']['mac']}\n";
|
|
|
|
?>
|
|
]]>
|
|
</programlisting>
|
|
</example>
|
|
</para>
|
|
</refsect1>
|
|
|
|
<refsect1 role="seealso">
|
|
&reftitle.seealso;
|
|
<para>
|
|
<simplelist>
|
|
<member><function>ssh2_connect</function></member>
|
|
</simplelist>
|
|
</para>
|
|
</refsect1>
|
|
|
|
</refentry>
|
|
|
|
<!-- Keep this comment at the end of the file
|
|
Local variables:
|
|
mode: sgml
|
|
sgml-omittag:t
|
|
sgml-shorttag:t
|
|
sgml-minimize-attributes:nil
|
|
sgml-always-quote-attributes:t
|
|
sgml-indent-step:1
|
|
sgml-indent-data:t
|
|
indent-tabs-mode:nil
|
|
sgml-parent-document:nil
|
|
sgml-default-dtd-file:"~/.phpdoc/manual.ced"
|
|
sgml-exposed-tags:nil
|
|
sgml-local-catalogs:nil
|
|
sgml-local-ecat-files:nil
|
|
End:
|
|
vim600: syn=xml fen fdm=syntax fdl=2 si
|
|
vim: et tw=78 syn=sgml
|
|
vi: ts=1 sw=1
|
|
-->
|