Differences

This shows you the differences between the selected revisions of the page.

session_url 2013-10-24 session_url 2013-10-24
Line 4: Line 4:
===== Syntax ===== ===== Syntax =====
-  [ sftp|ftp|ftps|scp :// ][ <username> [ : <password> ] @ ] <host> [ : <port> ]+  [ sftp|ftp|ftps|scp :// ][ <username> [ : <password> ] [ ; <fingerprint> ] @ ] <host> [ : <port> ]
===== Elements ===== ===== Elements =====
Line 11: Line 11:
The ''host'' can either be a host name (such as ''example.com''), an IPv4 address (such as ''127.0.0.1'') or an IPv6 address surrounded by square brackets (such as ''[2001:db8:85a3:8d3:1319:8a2e:370:7348]''). The ''host'' can either be a host name (such as ''example.com''), an IPv4 address (such as ''127.0.0.1'') or an IPv6 address surrounded by square brackets (such as ''[2001:db8:85a3:8d3:1319:8a2e:370:7348]'').
 +
 +===== [[hostkey]] SSH Host Key Fingerprint =====
 +
 +The SFTP/SCP URL can optionally contain expected [[ssh#verifying_the_host_key|SSH host key fingerprint]] with syntax ''fingerprint=<fingerprint>''.
 +
 +&beta_feature
 +
 +Providing the fingerprint in the session URL is mainly useful, if you need to provide all session settings using URL only, such as using [[integration#url|a hyperlink on a web page]].
 +
 +For security reasons, fingerprint provided in session URL does not override any fingerprint already cached on the machine. This for instance differs from behavior, when fingerprint is provided using ''-hostkey'' switch of ''[[scriptcommand_open|open]]'' command in scripting.
 +
 +Format of the fingerprint for URL((Fingerprint format for URL is based by [[http://tools.ietf.org/html/draft-ietf-secsh-scp-sftp-ssh-uri|draft-ietf-secsh-scp-sftp-ssh-uri]].)) somewhat differs from format used in other WinSCP features (''-hostkey'' switch of ''[[scriptcommand_open|open]]'' command in scripting for instance). To convert WinSCP fingerprint format to URL format:
 +
 +  - Drop bit count part (the number after ''ssh-rsa'' or ''ssh-dsa'', typically ''1024'' or ''2048'');
 +  - Replace remaining space and all colons ('':'') with a dash sign (''-'').
 +
 +For example WinSCP fingerprint ''ssh-rsa 2048 ee:f3:c1:59:4d:b4:e2:c5:da:22:3a:6e:97:a0:28:29'' converts to ''ssh-rsa-ee-f3-c1-59-4d-b4-e2-c5-da-22-3a-6e-97-a0-28-29''.
===== Special Characters ===== ===== Special Characters =====
-Special characters (like ''@'' in username, see example below) have to be encoded using ''%XX'' syntax, where ''XX'' is hexadecimal UTF-8 code.((For multi-byte codes, use ''%'' before every byte, for instance to represent pound-sign ''£'' use ''%C2%A3''.))+Special characters (like ''@'' in username, see example below) have to be encoded using ''%XX'' syntax, where ''XX'' is hexadecimal UTF-8 code.((For multi-byte codes, use ''%'' before every byte, for instance to represent pound-sign ''£'' use ''%C2%A3''.)) In versions prior to the latest beta release ASCII code is used. &beta
Common special characters are: Common special characters are:
Line 23: Line 40:
  * ''/'': ''%2F'' (slash)   * ''/'': ''%2F'' (slash)
  * ''@'': ''%40'' (at sign)   * ''@'': ''%40'' (at sign)
 +  * '';'': ''%59'' (semicolon)
===== Examples ===== ===== Examples =====
Line 32: Line 50:
  ftp://127.0.0.1:2121   ftp://127.0.0.1:2121
  ftp://[2001:db8:85a3:8d3:1319:8a2e:370:7348]:2121   ftp://[2001:db8:85a3:8d3:1319:8a2e:370:7348]:2121
- 
- 

Last modified: by martin