BGP ASNs¶
netutils.asn
¶
Functions for working with BGP ASNs.
asn_to_int(asplain)
¶
Convert AS Number to standardized asplain notation as an integer.
Parameters:
Name | Type | Description | Default |
---|---|---|---|
asplain |
str
|
An |
required |
Returns:
Type | Description |
---|---|
int
|
Integer value within of the given asplain value provided. |
Examples:
>>> from netutils.asn import asn_to_int
>>> asn_to_int("65000")
65000
>>> asn_to_int("65000.111")
4259840111
>>>