Linux premium71.web-hosting.com 4.18.0-513.11.1.lve.el8.x86_64 #1 SMP Thu Jan 18 16:21:02 UTC 2024 x86_64
LiteSpeed
Server IP : 198.187.29.8 & Your IP : 216.73.216.21
Domains :
Cant Read [ /etc/named.conf ]
User : cleahvkv
Terminal
Auto Root
Create File
Create Folder
Localroot Suggester
Backdoor Destroyer
Readme
/
lib /
python3.6 /
site-packages /
netaddr /
ip /
Delete
Unzip
Name
Size
Permission
Date
Action
__pycache__
[ DIR ]
drwxr-xr-x
2025-06-02 12:55
__init__.py
64.65
KB
-rw-r--r--
2019-11-18 17:08
glob.py
10.23
KB
-rw-r--r--
2019-11-18 17:08
iana.py
13.28
KB
-rw-r--r--
2019-11-18 17:08
ipv4-address-space.xml
74.29
KB
-rw-r--r--
2017-01-11 23:04
ipv6-address-space.xml
8.34
KB
-rw-r--r--
2017-01-11 23:04
ipv6-unicast-address-assignments.xml
14.71
KB
-rw-r--r--
2017-01-11 23:04
multicast-addresses.xml
132.29
KB
-rw-r--r--
2017-01-11 23:04
nmap.py
3.97
KB
-rw-r--r--
2019-11-18 17:08
rfc1924.py
1.71
KB
-rw-r--r--
2019-11-18 17:08
sets.py
25.94
KB
-rw-r--r--
2019-11-18 17:08
Save
Rename
#----------------------------------------------------------------------------- # Copyright (c) 2008 by David P. D. Moss. All rights reserved. # # Released under the BSD license. See the LICENSE file for details. #----------------------------------------------------------------------------- """A basic implementation of RFC 1924 ;-)""" from netaddr.core import AddrFormatError from netaddr.ip import IPAddress from netaddr.compat import _zip def chr_range(low, high): """Returns all characters between low and high chars.""" return [chr(i) for i in range(ord(low), ord(high) + 1)] #: Base 85 integer index to character lookup table. BASE_85 = ( chr_range('0', '9') + chr_range('A', 'Z') + chr_range('a', 'z') + ['!', '#', '$', '%', '&', '(', ')', '*', '+', '-', ';', '<', '=', '>', '?', '@', '^', '_', '`', '{', '|', '}', '~'] ) #: Base 85 digit to integer lookup table. BASE_85_DICT = dict(_zip(BASE_85, range(0, 86))) def ipv6_to_base85(addr): """Convert a regular IPv6 address to base 85.""" ip = IPAddress(addr) int_val = int(ip) remainder = [] while int_val > 0: remainder.append(int_val % 85) int_val //= 85 encoded = ''.join([BASE_85[w] for w in reversed(remainder)]) leading_zeroes = (20 - len(encoded)) * "0" return leading_zeroes + encoded def base85_to_ipv6(addr): """ Convert a base 85 IPv6 address to its hexadecimal format. """ tokens = list(addr) if len(tokens) != 20: raise AddrFormatError('Invalid base 85 IPv6 address: %r' % addr) result = 0 for i, num in enumerate(reversed(tokens)): num = BASE_85_DICT[num] result += (num * 85 ** i) ip = IPAddress(result, 6) return str(ip)