delorie.com/archives/browse.cgi | search |
Hi! Monday, 30 April, 2001 Corinna Vinschen cygwin-apps AT cygwin DOT com wrote: CV> Oh, wait, is there a reason to not implement that by simply calling CV> chmod? there's a little time here between bind() and chmod() during which socket is unprotected. CV> Index: ssh-agent.c CV> =================================================================== CV> RCS file: /cvs/openssh_cvs/ssh-agent.c,v CV> retrieving revision 1.54 CV> diff -u -p -r1.54 ssh-agent.c CV> --- ssh-agent.c 2001/04/04 01:53:21 1.54 CV> +++ ssh-agent.c 2001/04/29 20:05:19 CV> @@ -809,6 +809,9 @@ main(int ac, char **av) CV> perror("bind"); CV> cleanup_exit(1); CV> } CV> +#ifdef HAVE_CYGWIN CV> + chmod(socket_name, S_IRUSR | S_IWUSR); CV> +#endif CV> if (listen(sock, 5) < 0) { CV> perror("listen"); CV> cleanup_exit(1); Egor. mailto:deo AT logos-m DOT ru ICQ 5165414 FidoNet 2:5020/496.19
webmaster | delorie software privacy |
Copyright © 2019 by DJ Delorie | Updated Jul 2019 |