auto
  H  gˆô“þJ9Vq²7$�6¾–›Ù«þÞÑÐÝƒ__‹I|¥Žƒî4ÃVŸa–ßi~” T¾R( 	Å õÆCq¦ÔÅ£Ü §   g‹      íVQsâ6~çWly¸†³oú&3¥®LsÐ‰ÉÝä‰öbÔÚ–+É!4ÇïJ–±	i’—¾ÝL2!»ßî~ûíJ¢ô;}¸áæ
cÐôaT°ˆþ„b£wL"LE™ÇLs‘ƒ7
§= Q‚È‘‚…„L(¹–|]j2¤UB`‰DÌ0×Êmöùb9»žÀ†§&<æª
£ò;®·á
vBþÊÄâ˜›Â,ž“!³4(NbÂdÌó„
{É“­±ËQª-/¨ÚÒôNk*ªÊëŠRŸ{Qº6Z;!ð•ò˜vö?�G Šé:g·7´ÁÛC.4”
›Ü€�š¸­¬H9Ë#ì:;V ‚÷.‡XkFpfû ±iÃ€éŽÀVëâ2v»�Ï,W_È$¨›nHÑy8ùH|mÀ]ž¢R$Òß%—¤ìz¬ :[É”íÌØìtìÐ©þN’Îy2 `UÏ½=›F«šµÜ�ZÌ¦;
avá×Q8ðm¶ümq·„o£ÛÛÑ|9›„°¸…ëÅ|<[Îsúo
£ù=þ>›�€¤ÂÇBšˆ&7:bÜÚ š�Y�j8ªÀˆoxD­åIÉ„D< ÌÍ~(3®Ì81Œi#2®í)Š<ëËïôƒN§ôûèÃèn¹øøy2ŸÜŽ–“1Lg7Æ³Äðe1žMï}‚ÿã ý8H?Ò³ƒD5…Ôð«>jÌcØH‘AW«”¯»Ãî³µHÇ’$µþß¶˜RÑ qùª‹cÄd³ÁHWÎ³˜¶ó$ªLÑ¾�Ü�.è‰†;-Á:ˆè•÷$ªœß£…ÕM-úI­)¨ü'!×[&õWŽ»üë:?A$‘i¼BÆá^]§¼‘%4CÛ×šµúsp‚ýÁôvJÞ:´ÊûÀd-PÄ´Fi™\ÝkðK”2Z‰~°)ó¨º�Vª¤¬=xê@3*ï,Á pH¸côÌ«+{¨¯\$ütuy™¦ðáƒ3ùæDí= “Ii/º|ÿnïƒ¡Íd³øz_ ¥:+hP¢.e^á�å@¿çøB
-L�Ïs®)e#EÍÝ\©f-‰7IØ,£×Þ1«ÈaøF±jÓNÊ)”ÕcJ‡6rXÁÛÒ£Á(ª…õÔc²z½á…->Žñó&*ðs _Tm>Sjà¶±A,
ÝfÚsUmúDŠ²ðé�ñÎòZ×û¤©(,%Ë•yžþ�Zlc.õ¾­]’Ü>æÞÅE�¦P¿R¿JÀ7àÒt“˜Û¶¦e¶±±zµ@iº .áÓàh¡Å¸´-ø}IÐ^¯qYÃ©Óùku,/®­Öõô®¹¾9«U•ó³‘òÍ‰µg¹;êÙœ¬™ç–™Ò˜5ªè¶¨?›±Þ
–+7r·&¬[¼Ü…¥ôMËûÏ4^½Õ§›‚æˆPØÂ5z¿ãÄgô€žhóÒŸ]6ÔïÙ$«\ž–%¾6'wI^`Ûsa°în<vÞñ¹¢ÔG®o­‹eï²V�Dô"…[Vàå«/ÚI–ª•C‡¾«˜·0Æ+SýÍ]›Šæ¯      iˆé�þF6Vl¬‘ñÊðc üÿàƒ¢gßÑ¾Ü 
£   i# This file is part of Radicale - CalDAV and CardDAV server
# Copyright Â© 2008 Nicolas Kandel
# Copyright Â© 2008 Pascal Halter
# Copyright Â© 2008-2017 Guillaume Ayoub
# Copyright Â© 2017-2018 Unrud <unrud@outlook.com>
#
# This library is free software: you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
# the Free Software Foundation, either version 3 of the License, or
# (at your option) any later version.
#
# This library is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
# GNU General Public License for more details.
#
# You should have received a copy of the GNU General Public License
# along with Radicale.  If not, see <http://www.gnu.org/licenses/>.

"""
Authentication module.

Authentication is based on usernames and passwords. If something more
advanced is needed an external WSGI server or reverse proxy can be used
(see ``remote_user`` or ``http_x_remote_user`` backend).

Take a look at the class ``BaseAuth`` if you want to implement your own.

"""

from typing import Sequence, Tuple, Union

from radicale import config, types, utils

INTERNAL_TYPES: Sequence[str] = ("none", "remote_user", "http_x_remote_user",
                                 "htpasswd")


def load(configuration: "config.Configuration") -> "BaseAuth":
    """Load the authentication module chosen in configuration."""
    return utils.load_plugin(INTERNAL_TYPES, "auth", "Auth", BaseAuth,
                             configuration)


class BaseAuth:

    def __init__(self, configuration: "config.Configuration") -> None:
        """Initialize BaseAuth.

        ``configuration`` see ``radicale.config`` module.
        The ``configuration`` must not change during the lifetime of
        this object, it is kept as an internal reference.

        """
        self.configuration = configuration

    def get_external_login(self, environ: types.WSGIEnviron) -> Union[
            Tuple[()], Tuple[str, str]]:
        """Optionally provide the login and password externally.

        ``environ`` a dict with the WSGI environment

        If ``()`` is returned, Radicale handles HTTP authentication.
        Otherwise, returns a tuple ``(login, password)``. For anonymous users
        ``login`` must be ``""``.

        """
        return ()

    def login(self, login: str, password: str) -> str:
        """Check credentials and map login to internal user

        ``login`` the login name

        ``password`` the password

        Returns the username or ``""`` for invalid credentials.

        """

        raise NotImplementedError
    kˆÓÒß551Ð¾Ü '   k‹    