components/openssh/patches/002-pam_support.patch
author Jan Parcel <jan.parcel@oracle.com>
Mon, 01 Feb 2016 06:53:50 -0800
changeset 5376 4615bc2f4a50
parent 1612 3f2ec017627f
permissions -rw-r--r--
22631538 Patch comment incorrect/outdated for patch 039-sshd_config_5_defaults.patch

#
# To comply to the Solaris PAM policy, the UsePAM option is changed to be
# always on and not configurable on Solaris.  This is for Solaris only, so we
# will not contribute the changes to the upstream community.
#
*** orig/servconf.c	Mon Dec  5 17:23:03 2011
--- new/servconf.c	Wed Dec  7 13:41:04 2011
***************
*** 145,151 ****
--- 145,156 ----
  {
  	/* Portable-specific options */
  	if (options->use_pam == -1)
+ #ifdef SET_USE_PAM
+ 		/* use_pam should be always set to 1 on Solaris */
+ 		options->use_pam = 1;
+ #else
  		options->use_pam = 0;
+ #endif
  
  	/* Standard Options */
  	if (options->protocol == SSH_PROTO_UNKNOWN)
***************
*** 755,762 ****
--- 760,776 ----
  	switch (opcode) {
  	/* Portable-specific options */
  	case sUsePAM:
+ #ifdef SET_USE_PAM
+ 		/* UsePAM is always on and not configurable on Solaris */
+ 		logit("%s line %d: ignoring UsePAM option value."
+ 		    " This option is always on.", filename, linenum);
+ 		while (arg)
+ 			arg = strdelim(&cp);
+ 		break; 
+ #else
  		intptr = &options->use_pam;
  		goto parse_flag;
+ #endif
  
  	/* Standard Options */
  	case sBadOption: