+
    i                    n    ^ RI Ht ^ RIt^ RIt^ RIt^ RIt^RIHt RR.tRt	R R lt
R	 R
 ltR R ltR# )    )annotationsN)	BytesLike
accept_key
apply_maskz$258EAFA5-E914-47DA-95CA-C5AB0DC85B11c                   V ^8  d   QhRR/# )   returnstr )formats   "W/home/wkmabra/.openclaw/workspace/venv/lib/python3.14/site-packages/websockets/utils.py__annotate__r      s     * *c *    c                 v    \         P                  ! ^4      p \        P                  ! V 4      P	                  4       # )z:
Generate a random key for the Sec-WebSocket-Key header.

)secretstoken_bytesbase64	b64encodedecode)keys    r   generate_keyr      s.    
 

b
!CC ''))r   c                    V ^8  d   QhRRRR/# )r   r   r
   r	   r   )r   s   "r   r   r      s     	+ 	+C 	+C 	+r   c                    \         P                  ! V \        ,           P                  4       4      P	                  4       p\
        P                  ! V4      P                  4       # )zo
Compute the value of the Sec-WebSocket-Accept header.

Args:
    key: Value of the Sec-WebSocket-Key header.

)hashlibsha1GUIDencodedigestr   r   r   )r   r   s   & r   r   r      sB     <<t++-.557DD!((**r   c               $    V ^8  d   QhRRRRRR/# )r   datar   maskzbytes | bytearrayr	   bytesr   )r   s   "r   r   r   &   s'     D DY D&7 DE Dr   c                   \        V4      ^8w  d   \        R4      h\        P                  V \        P
                  4      pV\        V 4      ^,          ,          VR\        V 4      ^,           ,           p\        P                  V\        P
                  4      pW$,          P                  \        V 4      \        P
                  4      # )zk
Apply masking to the data of a WebSocket message.

Args:
    data: Data to mask.
    mask: 4-bytes mask.

zmask must contain 4 bytesN)len
ValueErrorint
from_bytessys	byteorderto_bytes)r    r!   data_intmask_repeatedmask_ints   &&   r   r   r   &   s     4yA~455~~dCMM2HCIN+d?SY].CCM~~mS]];H))#d)S]]CCr   )
__future__r   r   r   r   r(   typingr   __all__r   r   r   r   r   r   r   <module>r1      s:    "    
  
& .*	+Dr   