Call for testing.

Ben Lindstrom mouring at etoh.eviladmin.org
Mon Feb 25 06:45:54 EST 2002


On Sun, 24 Feb 2002, Manton, Doug wrote:

> > Eep.. I got a better idea.=) Lets leave the session structures where
> > they belong and just pass what we need from them to do the work.  Try
> > the attached patch.
>
> Good call.  I applied the patch, updated the prototype for aix_usrinfo
> but got the following when trying to compile session.c :
>
> xlC -qlanglvl=extended -I. -I.  -I/usr/local/include
> -DSSHDIR=\"/usr/local/etc\"  -D_PATH_SSH_PROGRAM=\"/usr/local/bin/ssh\"
> -D_PATH_SSH_ASKPASS_DEFAULT=\"/usr/local/libexec/ssh-askpass\"
> -D_PATH_SFTP_SERVER=\"/usr/local/libexec/sftp-server\"
> -D_PATH_SSH_PIDDIR=\"/var/run\"
> -DSSH_RAND_HELPER=\"/usr/local/libexec/ssh-rand-helper\" -DHAVE_CONFIG_H
> -c session.c
> "session.c", line 967.14: 1506-045 (S) Undeclared identifier cp.
> "session.c", line 1146.29: 1506-045 (S) Undeclared identifier s.
>

As for the cp issue...I'd rather do the following:

#ifdef _AIX
        {
                char *cp;

                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");
        }
#endif


I'll commit the changes to port-aix.[ch] since those are agreeable.

And I'll commit the above if it is also agreeable.  Which leaves us
with just dealing with aix_usrinfo(..);

During the week can you try putting aix_usrinfo(pw, s->tty, s->ttyfd)
before the do_setusercontext(pw) in do_child(s);  And see if we can
solve it that way?  I suspect that usrinfo() has to take place as
root and not as a normal user.

Otherwise I will have to see if Markus would be agreeable to change
do_setusercontext() to Session *s because some other platforms may need
other bits of the session structure down the road.

- Ben




More information about the openssh-unix-dev mailing list