openssh bug (AIX only): scp not found

K.Wolkersdorfer at K.Wolkersdorfer at
Tue Oct 16 02:48:00 EST 2001


Bug-Description (for AIX - current release 4.3.3 - only):

  Everything installed in /usr/opt/freeware/...
  Client uses in AIX:
    scp <local-file> user at host:<remote-file>
  System response:
    ksh: scp:  not found.
    lost connection


  In /etc/environment add
  to the PATH-variable.


  This problem exits in AIX only,
  although openssh seems properly configured with
  The culprit seems to be in AIX only code
  in session.c, line 1269 (openssh-2.9.9p2):

#ifdef _AIX
	if ((cp = getenv("AUTHSTATE")) != NULL)
		child_set_env(&env, &envsize, "AUTHSTATE", cp);
	if ((cp = getenv("KRB5CCNAME")) != NULL)
		child_set_env(&env, &envsize, "KRB5CCNAME", cp);
	read_environment_file(&env, &envsize, "/etc/environment");

  Here /etc/environment overrides unconditionally the PATH variable.
  But _PATH_STDPATH should always be added to the PATH variable
  (see CHANGELOG - tim at 2001/03/10 16:33:42) via:
  	child_set_env(&env, &envsize, "PATH", _PATH_STDPATH);


  The following fix works for us (openssh-2.9.9p2)
  diff session.c.orig session.c
< 	child_set_env(&env, &envsize, "PATH", _PATH_STDPATH);

Many thanks for your attention and best regards from Germany


Klaus Wolkersdorfer                     (K.Wolkersdorfer at
Zentralinstitut fuer Angewandte Mathematik (ZAM)  Tel: +49-2461-61-6579
John von Neumann - Institute for Computing (NIC)  Fax:            -6656
Forschungszentrum Juelich GmbH, D-52425 Juelich,  Germany

More information about the openssh-unix-dev mailing list