mirror of
https://github.com/jumpserver/jumpserver.git
synced 2025-05-06 07:06:23 +00:00
13 lines
273 B
Python
13 lines
273 B
Python
from django.conf import settings
|
|
|
|
from ..base import JMSModelBackend
|
|
|
|
|
|
class PasskeyAuthBackend(JMSModelBackend):
|
|
@staticmethod
|
|
def is_enabled():
|
|
return settings.AUTH_PASSKEY
|
|
|
|
def user_can_authenticate(self, user):
|
|
return user.source == 'local'
|