GIF89;aGIF89;aGIF89;a
Team Anon Force
https://t.me/Professor6T9x
Professor6T9 Web SheLL
Linux premium133.web-hosting.com 4.18.0-553.44.1.lve.el8.x86_64 #1 SMP Thu Mar 13 14:29:12 UTC 2025 x86_64
LiteSpeed
162.0.232.69
/
opt
/
imunify360
/
venv
/
lib
/
python3.11
/
site-packages
/
imav
/
simple_rpc
/
__pycache__
[ HOME ]
Exec
Submit
File Name : wordpress_security_plugin.cpython-311.pyc
� �}si � � � d Z ddlZddlZddlZddlmZmZmZ ddlm Z m Z ddlmZ ddl mZ ej e� � Z ddedz dedz d eedz edz f fd �Z G d� de� � Z G d � de� � ZdS )u This program is free software: you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation, either version 3 of the License, or (at your option) any later version. This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details. You should have received a copy of the GNU General Public License along with this program. If not, see <https://www.gnu.org/licenses/>. Copyright © 2019 Cloud Linux Software Inc. This software is also available under ImunifyAV commercial license, see <https://www.imunify360.com/legal/eula> � N)�CommonEndpoints� RootEndpoints�bind)�Scope�is_root_user)�MessageType)�get_wordpress_incidents�user�site_search�returnc �x � t j � � }t � � r�t � d| � � d}| �s t j | � � j }t � d| |� � n<# t $ r/ t � d| � � t d| � d�� � �w xY w||fS ||fS )a� Determine the user_id and site_path for filtering WordPress incidents. Three calling contexts: 1. Root user: Can query all incidents or filter by specific user 2. Non-root user: Can only query their own incidents (user/site_search ignored) 3. Proxy service: Both user and site_search must be set, restricted to that site Args: user: Username to filter by site_search: Site path to filter by Returns: Tuple of (user_id, site_path) to filter by, or (None, None) for all Raises: KeyError: If the specified user doesn't exist ValueError: If proxy service call is missing required parameters z-Root user querying incidents, user filter: %sNz(Filtering incidents for user %s (uid=%d)zUser not found: %szUser 'z' not found) �os�getuidr �logger�debug�pwd�getpwnam�pw_uid�KeyError�warning)r r �current_uid�user_ids �^/opt/imunify360/venv/lib/python3.11/site-packages/imav/simple_rpc/wordpress_security_plugin.py�get_user_id_and_site_for_queryr &