Admin escalator module for Python
Project description
adminpy - Python Admin access for most platforms
This module makes it easy to check system platform type and gain admin rights for scripts that require it.
This utilises PyUAC on the Windows platform and requires the use of Sudo on *NIX systems for admin rights escalation.
The purpose of this is to try and make people's life easier when needed more rights for python scripts.
Usage of the module
There are 3 functions of this module
- The sysinfo() function outputs whether the script recognises which type of system it's running on.
Example: On a Windows system, the script will output,"You are running on a Windows-based system."
-
The admincheck() function will output a "Yes" or "No", depending on if it has root or admin privilege
-
The runadmin() function will utilise ctypes function or Sudo (for linux) to relaunch script if does not have root or admin privilege
Requirements
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
File details
Details for the file adminpy-0.5.1.tar.gz
.
File metadata
- Download URL: adminpy-0.5.1.tar.gz
- Upload date:
- Size: 15.0 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/4.0.0 CPython/3.10.4
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | e7583a3b5704f9af4919fb357cd3e577320ca8f2c7aadefad15f497285c75d9e |
|
MD5 | d39a5b0d307475c7db596435e3e286ca |
|
BLAKE2b-256 | 44df4bf78cabfb1ae5656c6fd5eddb53c3e4731e46a2f139ea082a87c73b1427 |
File details
Details for the file adminpy-0.5.1-py3-none-any.whl
.
File metadata
- Download URL: adminpy-0.5.1-py3-none-any.whl
- Upload date:
- Size: 15.0 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/4.0.0 CPython/3.10.4
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | ea67ecae264ab26d706534d6e548ac29c119a10fca86ac5f882b2bcac60ca3e0 |
|
MD5 | c71db248a2c71e1f1e913d33e1e5bfdb |
|
BLAKE2b-256 | c32e150de3ca14ce39ba2fdaa759257285be1c9bb5743e5940074064cb2f4cb7 |