version 1.32, 2000/08/31 22:05:42 |
version 1.33, 2000/09/04 19:03:40 |
|
|
do_authenticated(struct passwd * pw) |
do_authenticated(struct passwd * pw) |
{ |
{ |
Session *s; |
Session *s; |
int type; |
int type, fd; |
int compression_level = 0, enable_compression_after_reply = 0; |
int compression_level = 0, enable_compression_after_reply = 0; |
int have_pty = 0; |
int have_pty = 0; |
char *command; |
char *command; |
|
|
break; |
break; |
} |
} |
strlcat(xauthfile, "/cookies", MAXPATHLEN); |
strlcat(xauthfile, "/cookies", MAXPATHLEN); |
open(xauthfile, O_RDWR|O_CREAT|O_EXCL, 0600); |
fd = open(xauthfile, O_RDWR|O_CREAT|O_EXCL, 0600); |
|
if (fd >= 0) |
|
close(fd); |
restore_uid(); |
restore_uid(); |
fatal_add_cleanup(xauthfile_cleanup_proc, NULL); |
fatal_add_cleanup(xauthfile_cleanup_proc, NULL); |
success = 1; |
success = 1; |
|
|
int |
int |
session_x11_req(Session *s) |
session_x11_req(Session *s) |
{ |
{ |
|
int fd; |
if (no_x11_forwarding_flag) { |
if (no_x11_forwarding_flag) { |
debug("X11 forwarding disabled in user configuration file."); |
debug("X11 forwarding disabled in user configuration file."); |
return 0; |
return 0; |
|
|
return 0; |
return 0; |
} |
} |
strlcat(xauthfile, "/cookies", MAXPATHLEN); |
strlcat(xauthfile, "/cookies", MAXPATHLEN); |
open(xauthfile, O_RDWR|O_CREAT|O_EXCL, 0600); |
fd = open(xauthfile, O_RDWR|O_CREAT|O_EXCL, 0600); |
|
if (fd >= 0) |
|
close(fd); |
restore_uid(); |
restore_uid(); |
fatal_add_cleanup(xauthfile_cleanup_proc, s); |
fatal_add_cleanup(xauthfile_cleanup_proc, s); |
return 1; |
return 1; |