Bugzilla – Attachment 2202 Details for
Bug 2053
Add option to allow skipping userauth_banner (patch)
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Requests
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
patch for the SkipBanner option
banner_skip.patch (text/plain), 2.57 KB, created by
Stanislaw Pitucha
on 2012-12-21 01:59:37 AEDT
(
hide
)
Description:
patch for the SkipBanner option
Filename:
MIME Type:
Creator:
Stanislaw Pitucha
Created:
2012-12-21 01:59:37 AEDT
Size:
2.57 KB
patch
obsolete
>diff -ru ssh/readconf.c ssh.new/readconf.c >--- ssh/readconf.c 2011-09-23 08:45:05.000000000 +0100 >+++ ssh.new/readconf.c 2012-12-20 14:36:00.741842504 +0000 >@@ -132,7 +132,8 @@ > oTunnel, oTunnelDevice, oLocalCommand, oPermitLocalCommand, > oVisualHostKey, oUseRoaming, oZeroKnowledgePasswordAuthentication, > oKexAlgorithms, oIPQoS, oRequestTTY, >- oDeprecated, oUnsupported >+ oDeprecated, oUnsupported, >+ oSkipBanner > } OpCodes; > > /* Textual representations of the tokens. */ >@@ -243,6 +244,7 @@ > { "kexalgorithms", oKexAlgorithms }, > { "ipqos", oIPQoS }, > { "requesttty", oRequestTTY }, >+ { "skipbanner", oSkipBanner }, > > { NULL, oBadOption } > }; >@@ -1040,6 +1042,10 @@ > *intptr = value; > break; > >+ case oSkipBanner: >+ intptr = &options->skip_banner; >+ goto parse_flag; >+ > case oDeprecated: > debug("%s line %d: Deprecated option \"%s\"", > filename, linenum, keyword); >@@ -1199,6 +1205,7 @@ > options->ip_qos_interactive = -1; > options->ip_qos_bulk = -1; > options->request_tty = -1; >+ options->skip_banner = -1; > } > > /* >@@ -1368,6 +1375,8 @@ > /* options->hostname will be set in the main program if appropriate */ > /* options->host_key_alias should not be set by default */ > /* options->preferred_authentications will be set in ssh */ >+ if (options->skip_banner == -1) >+ options->skip_banner = 0; > } > > /* >diff -ru ssh/readconf.h ssh.new/readconf.h >--- ssh/readconf.h 2011-09-23 08:45:05.000000000 +0100 >+++ ssh.new/readconf.h 2012-12-20 14:37:19.432497867 +0000 >@@ -135,6 +135,7 @@ > int use_roaming; > > int request_tty; >+ int skip_banner; > } Options; > > #define SSHCTL_MASTER_NO 0 >diff -ru ssh/ssh_config.5 ssh.new/ssh_config.5 >--- ssh/ssh_config.5 2012-06-29 14:57:25.000000000 +0100 >+++ ssh.new/ssh_config.5 2012-12-20 14:57:27.272522508 +0000 >@@ -1066,6 +1066,8 @@ > The default > is 0, indicating that these messages will not be sent to the server. > This option applies to protocol version 2 only. >+.It Cm SkipBanner >+Setting this option will hide the banner displayed during authentication. > .It Cm StrictHostKeyChecking > If this flag is set to > .Dq yes , >diff -ru ssh/sshconnect2.c ssh.new/sshconnect2.c >--- ssh/sshconnect2.c 2012-06-22 13:30:26.000000000 +0100 >+++ ssh.new/sshconnect2.c 2012-12-20 14:38:06.022884764 +0000 >@@ -473,7 +473,7 @@ > debug3("input_userauth_banner"); > raw = packet_get_string(&len); > lang = packet_get_string(NULL); >- if (len > 0 && options.log_level >= SYSLOG_LEVEL_INFO) { >+ if (len > 0 && options.log_level >= SYSLOG_LEVEL_INFO && !options.skip_banner) { > if (len > 65536) > len = 65536; > msg = xmalloc(len * 4 + 1); /* max expansion from strnvis() */
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Diff
View Attachment As Raw
Actions:
View
|
Diff
Attachments on
bug 2053
: 2202