Linux server1.dn-server.com 4.18.0-553.89.1.lve.el8.x86_64 #1 SMP Wed Dec 10 13:58:50 UTC 2025 x86_64
LiteSpeed
Server IP : 195.201.204.189 & Your IP : 216.73.216.60
Domains :
Cant Read [ /etc/named.conf ]
User : beriska1
Terminal
Auto Root
Create File
Create Folder
Localroot Suggester
Backdoor Destroyer
Readme
/
opt /
alt /
python311 /
lib64 /
python3.11 /
ctypes /
test /
Delete
Unzip
Name
Size
Permission
Date
Action
__pycache__
[ DIR ]
drwxr-xr-x
2026-05-05 23:07
__init__.py
445
B
-rw-r--r--
2026-03-03 04:22
__main__.py
68
B
-rw-r--r--
2026-03-03 04:22
test_anon.py
2.48
KB
-rw-r--r--
2026-03-03 04:22
test_array_in_pointer.py
1.7
KB
-rw-r--r--
2026-03-03 04:22
test_arrays.py
7.33
KB
-rw-r--r--
2026-03-03 04:22
test_as_parameter.py
7.08
KB
-rw-r--r--
2026-03-03 04:22
test_bitfields.py
10.11
KB
-rw-r--r--
2026-03-03 04:22
test_buffers.py
2.55
KB
-rw-r--r--
2026-03-03 04:22
test_bytes.py
1.94
KB
-rw-r--r--
2026-03-03 04:22
test_byteswap.py
13.09
KB
-rw-r--r--
2026-03-03 04:22
test_callbacks.py
10.38
KB
-rw-r--r--
2026-03-03 04:22
test_cast.py
3.64
KB
-rw-r--r--
2026-03-03 04:22
test_cfuncs.py
7.69
KB
-rw-r--r--
2026-03-03 04:22
test_checkretval.py
968
B
-rw-r--r--
2026-03-03 04:22
test_delattr.py
533
B
-rw-r--r--
2026-03-03 04:22
test_errno.py
2.12
KB
-rw-r--r--
2026-03-03 04:22
test_find.py
4.43
KB
-rw-r--r--
2026-03-03 04:22
test_frombuffer.py
5.09
KB
-rw-r--r--
2026-03-03 04:22
test_funcptr.py
3.93
KB
-rw-r--r--
2026-03-03 04:22
test_functions.py
12.03
KB
-rw-r--r--
2026-03-03 04:22
test_incomplete.py
1023
B
-rw-r--r--
2026-03-03 04:22
test_init.py
1.01
KB
-rw-r--r--
2026-03-03 04:22
test_internals.py
2.57
KB
-rw-r--r--
2026-03-03 04:22
test_keeprefs.py
3.18
KB
-rw-r--r--
2026-03-03 04:22
test_libc.py
1005
B
-rw-r--r--
2026-03-03 04:22
test_loading.py
7.1
KB
-rw-r--r--
2026-03-03 04:22
test_macholib.py
4.45
KB
-rw-r--r--
2026-03-03 04:22
test_memfunctions.py
3.22
KB
-rw-r--r--
2026-03-03 04:22
test_numbers.py
7.09
KB
-rw-r--r--
2026-03-03 04:22
test_objects.py
1.64
KB
-rw-r--r--
2026-03-03 04:22
test_parameters.py
10.81
KB
-rw-r--r--
2026-03-03 04:22
test_pep3118.py
8.48
KB
-rw-r--r--
2026-03-03 04:22
test_pickling.py
2.17
KB
-rw-r--r--
2026-03-03 04:22
test_pointers.py
7.07
KB
-rw-r--r--
2026-03-03 04:22
test_prototypes.py
6.68
KB
-rw-r--r--
2026-03-03 04:22
test_python_api.py
2.7
KB
-rw-r--r--
2026-03-03 04:22
test_random_things.py
2.77
KB
-rw-r--r--
2026-03-03 04:22
test_refcounts.py
3.06
KB
-rw-r--r--
2026-03-03 04:22
test_repr.py
842
B
-rw-r--r--
2026-03-03 04:22
test_returnfuncptrs.py
2.83
KB
-rw-r--r--
2026-03-03 04:22
test_simplesubclasses.py
1.26
KB
-rw-r--r--
2026-03-03 04:22
test_sizes.py
804
B
-rw-r--r--
2026-03-03 04:22
test_slicing.py
5.88
KB
-rw-r--r--
2026-03-03 04:22
test_stringptr.py
2.54
KB
-rw-r--r--
2026-03-03 04:22
test_strings.py
4.29
KB
-rw-r--r--
2026-03-03 04:22
test_struct_fields.py
3.08
KB
-rw-r--r--
2026-03-03 04:22
test_structures.py
30.95
KB
-rw-r--r--
2026-03-03 04:22
test_unaligned_structures.py
1.11
KB
-rw-r--r--
2026-03-03 04:22
test_unicode.py
1.95
KB
-rw-r--r--
2026-03-03 04:22
test_values.py
4.03
KB
-rw-r--r--
2026-03-03 04:22
test_varsize_struct.py
1.8
KB
-rw-r--r--
2026-03-03 04:22
test_win32.py
4.91
KB
-rw-r--r--
2026-03-03 04:22
test_wintypes.py
1.36
KB
-rw-r--r--
2026-03-03 04:22
Save
Rename
""" A testcase which accesses *values* in a dll. """ import _imp import importlib.util import unittest import sys from ctypes import * from test.support import import_helper import _ctypes_test class ValuesTestCase(unittest.TestCase): def test_an_integer(self): # This test checks and changes an integer stored inside the # _ctypes_test dll/shared lib. ctdll = CDLL(_ctypes_test.__file__) an_integer = c_int.in_dll(ctdll, "an_integer") x = an_integer.value self.assertEqual(x, ctdll.get_an_integer()) an_integer.value *= 2 self.assertEqual(x*2, ctdll.get_an_integer()) # To avoid test failures when this test is repeated several # times the original value must be restored an_integer.value = x self.assertEqual(x, ctdll.get_an_integer()) def test_undefined(self): ctdll = CDLL(_ctypes_test.__file__) self.assertRaises(ValueError, c_int.in_dll, ctdll, "Undefined_Symbol") class PythonValuesTestCase(unittest.TestCase): """This test only works when python itself is a dll/shared library""" def test_optimizeflag(self): # This test accesses the Py_OptimizeFlag integer, which is # exported by the Python dll and should match the sys.flags value opt = c_int.in_dll(pythonapi, "Py_OptimizeFlag").value self.assertEqual(opt, sys.flags.optimize) def test_frozentable(self): # Python exports a PyImport_FrozenModules symbol. This is a # pointer to an array of struct _frozen entries. The end of the # array is marked by an entry containing a NULL name and zero # size. # In standard Python, this table contains a __hello__ # module, and a __phello__ package containing a spam # module. class struct_frozen(Structure): _fields_ = [("name", c_char_p), ("code", POINTER(c_ubyte)), ("size", c_int), ("is_package", c_int), ("get_code", POINTER(c_ubyte)), # Function ptr ] FrozenTable = POINTER(struct_frozen) modules = [] for group in ["Bootstrap", "Stdlib", "Test"]: ft = FrozenTable.in_dll(pythonapi, f"_PyImport_Frozen{group}") # ft is a pointer to the struct_frozen entries: for entry in ft: # This is dangerous. We *can* iterate over a pointer, but # the loop will not terminate (maybe with an access # violation;-) because the pointer instance has no size. if entry.name is None: break modname = entry.name.decode("ascii") modules.append(modname) with self.subTest(modname): if entry.size != 0: # Do a sanity check on entry.size and entry.code. self.assertGreater(abs(entry.size), 10) self.assertTrue([entry.code[i] for i in range(abs(entry.size))]) # Check the module's package-ness. with import_helper.frozen_modules(): spec = importlib.util.find_spec(modname) if entry.is_package: # It's a package. self.assertIsNotNone(spec.submodule_search_locations) else: self.assertIsNone(spec.submodule_search_locations) with import_helper.frozen_modules(): expected = _imp._frozen_module_names() self.maxDiff = None self.assertEqual(modules, expected, "_PyImport_FrozenBootstrap example " "in Doc/library/ctypes.rst may be out of date") from ctypes import _pointer_type_cache del _pointer_type_cache[struct_frozen] def test_undefined(self): self.assertRaises(ValueError, c_int.in_dll, pythonapi, "Undefined_Symbol") if __name__ == '__main__': unittest.main()