Linux server2.hpierson.com 3.10.0-1160.105.1.el7.x86_64 #1 SMP Thu Dec 7 15:39:45 UTC 2023 x86_64
Apache
: 162.0.216.123 | : 216.73.216.152
28 Domain
?7.4.33
yvffpqmy
Terminal
AUTO ROOT
Adminer
Backdoor Destroyer
Linux Exploit
Lock Shell
Lock File
Create User
CREATE RDP
PHP Mailer
BACKCONNECT
UNLOCK SHELL
HASH IDENTIFIER
README
+ Create Folder
+ Create File
/
usr /
share /
systemtap /
runtime /
dyninst /
[ HOME SHELL ]
Name
Size
Permission
Action
addr-map.c
525
B
-rw-r--r--
alloc.c
1.16
KB
-rw-r--r--
arith.c
2.24
KB
-rw-r--r--
common_session_state.h
6.76
KB
-rw-r--r--
copy.c
4
KB
-rw-r--r--
debug.h
413
B
-rw-r--r--
ilog2.h
2.87
KB
-rw-r--r--
io.c
4.43
KB
-rw-r--r--
linux_defs.h
5.58
KB
-rw-r--r--
linux_hash.h
1.83
KB
-rw-r--r--
linux_types.h
654
B
-rw-r--r--
loc2c-runtime.h
2.44
KB
-rw-r--r--
map_list.h
1.03
KB
-rw-r--r--
map_runtime.h
5.04
KB
-rw-r--r--
namespaces.h
0
B
-rw-r--r--
offptr.h
4.68
KB
-rw-r--r--
offset_list.h
4.32
KB
-rw-r--r--
perf.c
0
B
-rw-r--r--
print.c
2.37
KB
-rw-r--r--
probe_lock.h
1.81
KB
-rw-r--r--
regs.c
2.14
KB
-rw-r--r--
runtime.h
9.49
KB
-rw-r--r--
runtime_context.h
6.4
KB
-rw-r--r--
runtime_defines.h
235
B
-rw-r--r--
session_attributes.c
1.68
KB
-rw-r--r--
session_attributes.h
772
B
-rw-r--r--
shm.c
6.03
KB
-rw-r--r--
stapdyn.h
3.37
KB
-rw-r--r--
stat_runtime.h
1.79
KB
-rw-r--r--
sym.c
40
B
-rw-r--r--
task_finder.c
0
B
-rw-r--r--
timer.c
2.71
KB
-rw-r--r--
transport.c
30.4
KB
-rw-r--r--
transport.h
3.88
KB
-rw-r--r--
unwind.c
0
B
-rw-r--r--
uprobes-regs.c
1.94
KB
-rw-r--r--
uprobes.c
1.76
KB
-rw-r--r--
uprobes.h
953
B
-rw-r--r--
Delete
Unzip
Zip
${this.title}
Close
Code Editor : common_session_state.h
// Will be included once by runtime/common_session_state.h, which is included // once by translate.cxx c_unparser::emit_common_header (). // Forward declarations for things in runtime/dyninst/shm.c static void *_stp_shm_base; static void *_stp_shm_alloc(size_t size); #include "session_attributes.h" #include "transport.h" // Global state shared throughout the module struct stp_runtime_session { atomic_t _session_state; atomic_t _error_count; atomic_t _skipped_count; atomic_t _skipped_count_lowstack; atomic_t _skipped_count_reentrant; atomic_t _skipped_count_uprobe_reg; atomic_t _skipped_count_uprobe_unreg; unsigned long _hash_seed; struct _stp_session_attributes _session_attributes; #ifdef STP_ALIBI atomic_t _probe_alibi[STP_PROBE_COUNT]; #endif #ifdef STP_TIMING offptr_t _probe_timing[STP_PROBE_COUNT]; // offptr<Stat> #endif struct stp_globals _global; struct _stp_transport_session_data _transport_data; // NB: the context includes a number of pointers, which wouldn't be // kosher for shared memory, but it's ok as long as they're only set // and dereferenced within each separate handler invocation. struct context _context[]; // variably-sized to cpu count }; static inline struct stp_runtime_session* _stp_session(void) { // Since the session is always the first thing allocated, it lives // directly at the start of shared memory. // NB: We always reference the main shm pointer, rather than our own // local copy, because reallocations may cause it to move dynamically. return _stp_shm_base; } #define GET_SESSION_ATOMIC(name) \ static inline atomic_t *name(void) { \ if (unlikely(_stp_session() == NULL)) \ return NULL; \ return &_stp_session()->_##name; \ } GET_SESSION_ATOMIC(session_state); GET_SESSION_ATOMIC(error_count); GET_SESSION_ATOMIC(skipped_count); GET_SESSION_ATOMIC(skipped_count_lowstack); GET_SESSION_ATOMIC(skipped_count_reentrant); GET_SESSION_ATOMIC(skipped_count_uprobe_reg); GET_SESSION_ATOMIC(skipped_count_uprobe_unreg); #undef GET_SESSION_ATOMIC static inline unsigned long _stap_hash_seed() { if (likely(_stp_session())) return _stp_session()->_hash_seed; return 0; } static inline struct _stp_session_attributes *stp_session_attributes(void) { if (likely(_stp_session())) return &_stp_session()->_session_attributes; return NULL; } #ifdef STP_ALIBI static inline atomic_t *probe_alibi(size_t index) { // Do some simple bounds-checking. Translator-generated code // should never get this wrong, but better to be safe. index = clamp_t(size_t, index, 0, STP_PROBE_COUNT - 1); if (likely(_stp_session())) return &_stp_session()->_probe_alibi[index]; return NULL; } #endif #ifdef STP_TIMING static inline Stat probe_timing(size_t index) { // Do some simple bounds-checking. Translator-generated code // should never get this wrong, but better to be safe. index = clamp_t(size_t, index, 0, STP_PROBE_COUNT - 1); if (likely(_stp_session())) return offptr_get(&_stp_session()->_probe_timing[index]); return NULL; } #endif static inline struct context* stp_session_context(size_t index) { // Do some simple bounds-checking. Translator-generated code // should never get this wrong, but better to be safe. index = clamp_t(size_t, index, 0, _stp_runtime_num_contexts - 1); if (likely(_stp_session())) return &_stp_session()->_context[index]; return NULL; } static inline struct _stp_transport_session_data *stp_transport_data(void) { if (_stp_session()) return &_stp_session()->_transport_data; return NULL; } #define _global_raw(name) (_stp_session()->_global.name) #define _global_type(name) typeof(_global_raw(name)) #define _global_cast_type(name) _global_type(name ## _typed) #define _global_offptr_p(name) \ __builtin_types_compatible_p(_global_type(name), offptr_t) #define _global_compat_p(name, value) \ __builtin_types_compatible_p(_global_cast_type(name), typeof(value)) // NB: The (offptr_t*) cast is unfortunately necessary for the first expression // to pass syntax on long/string types, but __builtin_choose_expr will still // direct them to the second expression due to the _global_offptr_p check. #define global(name) \ __builtin_choose_expr(_global_offptr_p(name), \ ((_global_cast_type(name)) \ offptr_get((offptr_t*)&_global_raw(name))), \ _global_raw(name)) // NB: This is only used for pointer->offptr assignments, for stats and maps. // Unlike global() which just returns string/long types by value, here we'd // have to encode their separate assignment schemes, in a way that stays // syntax-compatible with all others. The translator can do that simpler. // NB: Evaluate the value *before* the offptr destination is computed, in // case the value's allocation causes shm to move. #define global_set(name, value) ({ \ typeof(value) __value = (value); \ offptr_set(&_global_raw(name), \ __builtin_choose_expr(_global_compat_p(name, __value), \ __value, (void)0)); \ __value; }) #define global_lock(name) (&_global_raw(name ## _lock)) #define global_lock_init(name) \ stp_pthread_rwlock_init_shared(global_lock(name)) #ifdef STP_TIMING #define global_skipped(name) (&_global_raw(name ## _lock_skip_count)) #define global_contended(name) (&_global_raw(name ## _lock_contention_count)) #endif static int stp_session_init(void) { size_t i; // Reserve space for the session at the beginning of shared memory. size_t session_size = sizeof(struct stp_runtime_session) + sizeof(struct context) * _stp_runtime_num_contexts; void *session = _stp_shm_zalloc(session_size); if (!session) return -ENOMEM; // If we weren't the very first thing allocated, then something is wrong! if (session != _stp_shm_base) return -EINVAL; atomic_set(session_state(), STAP_SESSION_UNINITIALIZED); atomic_set(error_count(), 0); atomic_set(skipped_count(), 0); atomic_set(skipped_count_lowstack(), 0); atomic_set(skipped_count_reentrant(), 0); atomic_set(skipped_count_uprobe_reg(), 0); atomic_set(skipped_count_uprobe_unreg(), 0); _stp_session()->_hash_seed = _stp_random_u ((unsigned long)-1); stp_session_attributes_init(); #ifdef STP_ALIBI // Initialize all the alibi counters for (i = 0; i < STP_PROBE_COUNT; ++i) atomic_set(probe_alibi(i), 0); #endif #ifdef STP_TIMING // Initialize each Stat used for timing information for (i = 0; i < STP_PROBE_COUNT; ++i) { // NB: we don't check for null return here, but instead at // passage to probe handlers and at final printing. Stat st = _stp_stat_init(STAT_OP_MIN, STAT_OP_MAX, STAT_OP_AVG, NULL); // NB: allocate first, then dereference the session after, in case // allocation-resizing causes the whole thing to move around. offptr_set(&_stp_session()->_probe_timing[i], st); } #endif return _stp_dyninst_transport_session_init(); } static int stp_session_init_finished(void) { return stp_dyninst_session_init_finished(); }
Close