
    9i                     J    d Z ddlmZ ddlmZ  G d dej
                        Zy)z1
Custom admin site with reCAPTCHA v3 protection.
    )admin   )"RecaptchaV3AdminAuthenticationFormc                   2     e Zd ZdZdZdZdZeZ fdZ	 xZ
S )RecaptchaAdminSitezH
    Custom admin site that uses reCAPTCHA v3 for login protection.
    zHU CMS AdministrationzHU CMS Adminz Welcome to HU CMS Administrationc                 P    t         |   |      }ddlm} |j                  |d<   |S )z?
        Add reCAPTCHA public key to template context.
        r   )settingsrecaptcha_public_key)supereach_contextdjango.confr	   RECAPTCHA_PUBLIC_KEY)selfrequestcontextr	   	__class__s       (/var/www/apihucms/apihucms/admin_site.pyr   zRecaptchaAdminSite.each_context   s-     '&w/(*2*G*G&'    )__name__
__module____qualname____doc__site_header
site_titleindex_titler   
login_formr   __classcell__)r   s   @r   r   r      s(     *KJ4K3J r   r   N)r   django.contribr   admin_formsr   	AdminSiter    r   r   <module>r"      s"    ! ; r   