This commit is contained in:
Thomas Waldmann 2013-11-10 08:03:36 +01:00
parent 367bc70f56
commit 50bdf58398

View File

@ -193,7 +193,7 @@ class NicUpdateView(View):
if not check_api_auth(username, password):
logger.info('%s - received bad credentials, username: %s' % (hostname, username, ))
return basic_challenge("authenticate to update DNS", 'badauth')
logging.info("authenticated by update secret for host %s" % username)
logger.info("authenticated by update secret for host %s" % username)
if hostname is None:
# as we use update_username == hostname, we can fall back to that:
hostname = username
@ -238,7 +238,7 @@ class AuthorizedNicUpdateView(View):
if not check_session_auth(request.user, hostname):
logger.info('%s - is not owned by user: %s' % (hostname, request.user.username, ))
return Response('nohost')
logging.info("authenticated by session as user %s, creator of host %s" % (request.user.username, hostname))
logger.info("authenticated by session as user %s, creator of host %s" % (request.user.username, hostname))
ipaddr = request.GET.get('myip')
if not ipaddr:
ipaddr = request.META.get('REMOTE_ADDR')