HEX
Server: LiteSpeed
System: Linux us-phx-web1284.main-hosting.eu 4.18.0-553.109.1.lve.el8.x86_64 #1 SMP Thu Mar 5 20:23:46 UTC 2026 x86_64
User: u300739242 (300739242)
PHP: 8.2.30
Disabled: system, shell_exec, passthru, mysql_list_dbs, ini_alter, dl, symlink, link, chgrp, leak, popen, apache_child_terminate, virtual, mb_send_mail
Upload Files
File: //opt/alt/python37/lib/python3.7/site-packages/exabgp/netlink/__pycache__/attributes.cpython-37.pyc
B

RP�eb�@sddZddlmZddlmZddlmZddlmZddlmZGdd�de�Z	Gd	d
�d
e
�ZdS)z�
attributes.py

Created by Thomas Mangin on 2015-03-31.
Copyright (c) 2009-2017 Exa Networks. All rights reserved.
License: 3-clause BSD. (See the COPYRIGHT file)
�)�pack)�unpack)�calcsize)�concat_bytes_i)�NetLinkErrorc@seZdZdS)�AttributesErrorN)�__name__�
__module__�__qualname__�rr�J/opt/alt/python37/lib/python3.7/site-packages/exabgp/netlink/attributes.pyrsrc@sDeZdZGdd�de�ZGdd�de�Zedd��Zedd��Zd	S)
�
Attributesc@seZdZdZee�ZdS)zAttributes.HeaderZHHN)rr	r
�PACKr�LENrrrr�Headersrc@s,eZdZdZdZdZdZdZdZdZ	dZ
d	S)
zAttributes.Typer�������N)rr	r
Z
IFA_UNSPECZIFA_ADDRESSZ	IFA_LOCALZ	IFA_LABELZ
IFA_BROADCASTZIFA_ANYCASTZ
IFA_CACHEINFOZ
IFA_MULTICASTrrrr�Typesrccs�x||r|t|jj|d|jj��\}}t|�|krDtdt|�|f��||jj|�}||fV|t|dd�dd�}qWdS)NzBuffer underrun %d < %drr)rrrr�lenr�int)�cls�data�length�atype�payloadrrr�decode&s
zAttributes.decodecs&�fdd��t�fdd�|��D��S)NcsRddd�}�jjt|�}t�jj||�|}||�t|�}|rN|d|7}|S)NrcSs||d|d@S)Nrr)r�torrr�pad3sz/Attributes.encode.<locals>._encode.<locals>.pad�)r)rrrrr)rrr"r�raw)rrr�_encode2s
z"Attributes.encode.<locals>._encodec3s|]\}}�||�VqdS)Nr)�.0�k�v)r%rr�	<genexpr>=sz$Attributes.encode.<locals>.<genexpr>)r�items)r�
attributesr)r%rr�encode0szAttributes.encodeN)	rr	r
�objectrr�classmethodr r,rrrrr
s

r
N)�__doc__�structrrrZexabgp.utilrZexabgp.netlinkrrr-r
rrrr�<module>s