Read ACL in slave service loop
authorClinton Ebadi <clinton@unknownlamer.org>
Fri, 7 Dec 2012 16:42:32 +0000 (11:42 -0500)
committerClinton Ebadi <clinton@unknownlamer.org>
Fri, 7 Dec 2012 16:42:32 +0000 (11:42 -0500)
At least the firewall needs to query permissions. Acl.read has the
handy attribute of clearing the current ACL. I think the main service
function sould also be re-reading the permissions on each loop, or
perhaps not because it may call setupUser instead? Investigate.

src/main.sml

index f2beee8..28834af 100644 (file)
@@ -1626,7 +1626,8 @@ fun slave () =
        val _ = print ("Slave server starting at " ^ now () ^ "\n")
 
        fun loop () =
        val _ = print ("Slave server starting at " ^ now () ^ "\n")
 
        fun loop () =
-           (case OpenSSL.accept sock of
+           (Acl.read Config.aclFile;
+            case OpenSSL.accept sock of
                 NONE => ()
               | SOME bio =>
                 let
                 NONE => ()
               | SOME bio =>
                 let