[Zodb-checkins] CVS: ZODB3/ZEO - runzeo.py:1.12.10.3
StorageServer.py:1.92.10.6 ClientStorage.py:1.93.2.6
Jeremy Hylton
jeremy at zope.com
Thu May 29 18:30:11 EDT 2003
Update of /cvs-repository/ZODB3/ZEO
In directory cvs.zope.org:/tmp/cvs-serv26060/ZEO
Modified Files:
Tag: ZODB3-auth-branch
runzeo.py StorageServer.py ClientStorage.py
Log Message:
Merge new test configuration changes from trunk.
=== ZODB3/ZEO/runzeo.py 1.12.10.2 => 1.12.10.3 ===
--- ZODB3/ZEO/runzeo.py:1.12.10.2 Thu May 29 12:27:53 2003
+++ ZODB3/ZEO/runzeo.py Thu May 29 17:30:10 2003
@@ -89,10 +89,12 @@
"t:", "timeout=", float)
self.add("monitor_address", "zeo.monitor_address", "m:", "monitor=",
self.handle_monitor_address)
- self.add('auth_protocol', 'zeo.authentication_protocol', None,
- 'auth-protocol=', default=None)
- self.add('auth_filename', 'zeo.authentication_database', None,
- 'auth-filename=')
+ self.add('auth_protocol', 'zeo.authentication_protocol',
+ None, 'auth-protocol=', default=None)
+ self.add('auth_database', 'zeo.authentication_database',
+ None, 'auth-database=')
+ self.add('auth_realm', 'zeo.authentication_realm',
+ None, 'auth-realm=')
class ZEOOptions(ZDOptions, ZEOOptionsMixin):
@@ -194,7 +196,8 @@
transaction_timeout=self.options.transaction_timeout,
monitor_address=self.options.monitor_address,
auth_protocol=self.options.auth_protocol,
- auth_filename=self.options.auth_filename)
+ auth_database=self.options.auth_database,
+ auth_realm=self.options.auth_realm)
def loop_forever(self):
import ThreadedAsync.LoopCallback
=== ZODB3/ZEO/StorageServer.py 1.92.10.5 => 1.92.10.6 ===
--- ZODB3/ZEO/StorageServer.py:1.92.10.5 Thu May 29 12:27:53 2003
+++ ZODB3/ZEO/StorageServer.py Thu May 29 17:30:10 2003
@@ -610,7 +610,8 @@
transaction_timeout=None,
monitor_address=None,
auth_protocol=None,
- auth_filename=None):
+ auth_filename=None,
+ auth_realm=None):
"""StorageServer constructor.
This is typically invoked from the start.py script.
@@ -683,6 +684,7 @@
self.read_only = read_only
self.auth_protocol = auth_protocol
self.auth_filename = auth_filename
+ self.auth_realm = auth_realm
self.database = None
if auth_protocol:
self._setup_auth(auth_protocol)
@@ -712,23 +714,23 @@
# Can't be done in global scope, because of cyclic references
from ZEO.auth import get_module
+ name = self.__class__.__name__
+
module = get_module(protocol)
if not module:
- log("%s: no such an auth protocol: %s" %
- (self.__class__.__name__, protocol))
+ log("%s: no such an auth protocol: %s" % (name, protocol))
return
storage_class, client, db_class = module
if not storage_class or not issubclass(storage_class, ZEOStorage):
log(("%s: %s isn't a valid protocol, must have a StorageClass" %
- (self.__class__.__name__, protocol)))
+ (name, protocol)))
self.auth_protocol = None
return
self.ZEOStorageClass = storage_class
- log("%s: using auth protocol: %s" % \
- (self.__class__.__name__, protocol))
+ log("%s: using auth protocol: %s" % (name, protocol))
# We create a Database instance here for use with the authenticator
# modules. Having one instance allows it to be shared between multiple
=== ZODB3/ZEO/ClientStorage.py 1.93.2.5 => 1.93.2.6 ===
--- ZODB3/ZEO/ClientStorage.py:1.93.2.5 Thu May 29 12:27:53 2003
+++ ZODB3/ZEO/ClientStorage.py Thu May 29 17:30:10 2003
@@ -35,7 +35,7 @@
from ZODB import POSException
from ZODB.TimeStamp import TimeStamp
-from zLOG import LOG, PROBLEM, INFO, BLATHER
+from zLOG import LOG, PROBLEM, INFO, BLATHER, ERROR
def log2(type, msg, subsys="ZCS:%d" % os.getpid()):
LOG(subsys, type, msg)
@@ -416,6 +416,7 @@
if auth:
skey = self.doAuth(auth, stub)
if not skey:
+ log2(ERROR, "Authentication failed")
raise AuthError, "Authentication failed"
try:
More information about the Zodb-checkins
mailing list