]> asedeno.scripts.mit.edu Git - PuTTY.git/blobdiff - windows/winsftp.c
Log when -restrict-acl is in use.
[PuTTY.git] / windows / winsftp.c
index c786f7a65d686d65d165391674e878ed42fd7e91..437ef439d0c23651cb2f7bee8ad8be79350b1359 100644 (file)
@@ -747,23 +747,11 @@ char *ssh_sftp_get_cmdline(const char *prompt, int no_fds_ok)
     return ctx->line;
 }
 
-void platform_psftp_post_option_setup(void)
+void platform_psftp_pre_conn_setup(void)
 {
-#if !defined UNPROTECT && !defined NO_SECURITY
-    /*
-     * Protect our process.
-     */
-    {
-        char *error = NULL;
-        if (!setprocessacl(error)) {
-            char *message = dupprintf("Could not restrict process ACL: %s",
-                                      error);
-            logevent(NULL, message);
-            sfree(message);
-            sfree(error);
-        }
+    if (restricted_acl) {
+       logevent(NULL, "Running with restricted process ACL");
     }
-#endif
 }
 
 /* ----------------------------------------------------------------------
@@ -773,6 +761,8 @@ int main(int argc, char *argv[])
 {
     int ret;
 
+    dll_hijacking_protection();
+
     ret = psftp_main(argc, argv);
 
     return ret;