Beispiel #1
0
 def testRejectAuthenticated(self):
     self.config["nuauth_reject_after_timeout"] = 0
     self.config["nuauth_reject_authenticated_drop"] = 1
     self.nuauth = Nuauth(self.config)
     user = self.users[0]
     client = user.createClientWithCerts()
     testPortFailure(self, self.iptables, client, VALID_PORT, ECONNREFUSED)
     client.stop()
Beispiel #2
0
 def testDrop(self):
     self.config["nuauth_reject_after_timeout"] = "0"
     self.config["nuauth_reject_authenticated_drop"] = "0"
     self.nuauth = Nuauth(self.config)
     user = self.users[0]
     client = user.createClientWithCerts()
     testPortFailure(self, self.iptables, client, VALID_PORT, ETIMEDOUT)
     client.stop()
Beispiel #3
0
 def testRejectAuthenticated(self):
     self.config["nuauth_reject_after_timeout"] = 0
     self.config["nuauth_reject_authenticated_drop"] = 1
     self.nuauth = Nuauth(self.config)
     user = self.users[0]
     client = user.createClientWithCerts()
     testPortFailure(self, self.iptables, client, VALID_PORT, ECONNREFUSED)
     client.stop()
Beispiel #4
0
 def testDrop(self):
     self.config["nuauth_reject_after_timeout"] = "0"
     self.config["nuauth_reject_authenticated_drop"] = "0"
     self.nuauth = Nuauth(self.config)
     user = self.users[0]
     client = user.createClientWithCerts()
     testPortFailure(self, self.iptables, client, VALID_PORT, ETIMEDOUT)
     client.stop()
Beispiel #5
0
 def testRejectTimedout(self):
     self.config["nuauth_reject_after_timeout"] = "1"
     self.config["nuauth_reject_authenticated_drop"] = "0"
     self.nuauth = Nuauth(self.config)
     testPortFailure(self, self.iptables, None, VALID_PORT, ECONNREFUSED)
Beispiel #6
0
 def testRejectTimedout(self):
     self.config["nuauth_reject_after_timeout"] = "1"
     self.config["nuauth_reject_authenticated_drop"] = "0"
     self.nuauth = Nuauth(self.config)
     testPortFailure(self, self.iptables, None, VALID_PORT, ECONNREFUSED)