Make cookie file not world-readable. Fixes http://bugs.debian.org/649384
authorGabriele Giacone <1o5g4r8o@gmail.com>
Sun, 20 Nov 2011 16:27:42 +0000 (17:27 +0100)
committerGabriele Giacone <1o5g4r8o@gmail.com>
Sun, 20 Nov 2011 16:27:42 +0000 (17:27 +0100)
plugin/npapi/plugin.cpp

index e161a1d..04950e6 100644 (file)
@@ -1108,6 +1108,7 @@ nsPluginInstance::setupCookies(const std::string& pageurl)
     ss << "/tmp/gnash-cookies." << getpid();
 
     cookiefile.open(ss.str().c_str(), std::ios::out | std::ios::trunc);
+    chmod (ss.str().c_str(), 0600);
 
     // Firefox provides cookies in the following format:
     //