
    k7i                     J    S SK Jr  S SKJr  S\S\\   4S jr " S S\5      rg)	    )AuthlibHTTPError)add_params_to_uritextreturnc                    ^ / SQn[        U 5       V^s/ s H!  m[        U4S jU 5       5      (       a  M  TPM#     sn$ s  snf )zCheck whether the string only contains characters from the restricted ASCII set defined in RFC6749 for errors.

https://datatracker.ietf.org/doc/html/rfc6749#section-4.1.2.1
))    !   )#   [   )]   ~   c              3   d   >#    U  H%  u  pU[        T5      s=:*  =(       a    U:*  Os  v   M'     g 7fN)ord).0startendchars      M/home/james-whalen/.local/lib/python3.13/site-packages/authlib/oauth2/base.py	<genexpr>+invalid_error_characters.<locals>.<genexpr>   s'     L|5CI,,,,|s   -0)setany)r   valid_rangesr   s     `r   invalid_error_charactersr      sC    
L IDL|LL 	  s   ??c                   V   ^  \ rS rSr       SU 4S jjrU 4S jrSU 4S jjrSrU =r$ )OAuth2Error   c                    > U(       a0  [        U5      =n(       a  [        SSR                  U5       S35      e[        T	U ]  XqX#5        X@l        XPl        X`l        g )Nz1Error description contains forbidden characters: z, .)r   
ValueErrorjoinsuper__init__stateredirect_uriredirect_fragment)
selfdescriptionuristatus_coder%   r&   r'   errorchars	__class__s
            r   r$   OAuth2Error.__init__   s_     0==u= G		RWHXGYYZ[  	S>
(!2    c                    > [         TU ]  5       nU R                  (       a  UR                  SU R                  45        U$ )zGet a list of body.r%   )r#   get_bodyr%   append)r(   r,   r.   s     r   r2   OAuth2Error.get_body2   s1     "::LL'4::./r0   c                    > U R                   (       a8  U R                  5       n[        U R                   X R                  5      nSSSU4/4$ [        TU ]  US9$ )Ni.   Location)r*   )r&   r2   r   r'   r#   __call__)r(   r*   paramslocr.   s       r   r8   OAuth2Error.__call__9   sW    ]]_F#D$5$5v?U?UVCj#.///wC((r0   )r'   r&   r%   )NNNNNFNr   )	__name__
__module____qualname____firstlineno__r$   r2   r8   __static_attributes____classcell__)r.   s   @r   r   r      s.     34) )r0   r   N)authlib.common.errorsr   authlib.common.urlsr   strlistr   r    r0   r   <module>rG      s/    2 13 49 $')" ')r0   