diff --git a/hgext/factotum.py b/hgext/factotum.py --- a/hgext/factotum.py +++ b/hgext/factotum.py @@ -101,7 +101,7 @@ def find_user_password(self, realm, auth user, passwd = auth.get('username'), auth.get('password') if not user or not passwd: if not prefix: - prefix = '*' + prefix = realm.split(' ')[0].lower() params = 'service=%s prefix=%s' % (_service, prefix) if user: params = '%s user=%s' % (params, user)