Rename the volume_list RPC call to lv_list
[ganeti-local] / lib / http / auth.py
index dc4c801..b9a66a5 100644 (file)
@@ -40,7 +40,7 @@ HTTP_BASIC_AUTH = "Basic"
 HTTP_DIGEST_AUTH = "Digest"
 
 # Not exactly as described in RFC2616, section 2.2, but good enough
-_NOQUOTE = re.compile(r"^[-_a-z0-9]$", re.I)
+_NOQUOTE = re.compile(r"^[-_a-z0-9]+$", re.I)
 
 
 def _FormatAuthHeader(scheme, params):
@@ -188,7 +188,7 @@ class HttpServerRequestAuthentication(object):
 
     return self.Authenticate(req, user, password)
 
-  def AuthenticateBasic(self, req, user, password):
+  def Authenticate(self, req, user, password):
     """Checks the password for a user.
 
     This function MUST be overriden by a subclass.