semvec/pypi-packages huggingface dataset:
aws-priv-actions 1.0.0
CLI for privileged actions on AWS member accounts
Requires Python: >=3.10

# AWS Privileged Actions CLI (`aws-priv-actions`)

A command-line interface for performing privileged actions on AWS member accounts in an organization, when [Centralized Root Management](https://docs.aws.amazon.com/IAM/latest/UserGuide/id_root-enable-root-access.html) is enabled.

> ⚠️ **Disclaimer**
>
> This software allows you to assume AWS IAM `root` privileges, which can have significant security and operational impacts if misused. Use with caution. The authors and contributors provide this software "as is", without warranty of any kind, express or implied. You are solely responsible for any actions taken using this tool.

## Why?

As of the time of writing, there is no AWS API to fetch the list of available task policies. This is a workaround to allow you to perform privileged actions on AWS member accounts in an organization.

This was built as a simple tool to allow Operators to use the `assume-root` feature of AWS Centralized Root Management in critical situations requring root access, without having to pour over AWS CLI documentation.

## Installation

```bash
pip install aws-priv-actions
```

## Prerequisites

- Python 3.8 or higher
- AWS CLI configured with appropriate credentials
- Required IAM permissions to perform privileged actions

## Usage

### List Available Task Policies

```bash
aws-priv-actions list-policies
```

### Assume Root Privileges

```bash
aws-priv-actions assume-root <target-principal> <task-policy> [--duration-seconds SECONDS] [--region REGION] [--verbose]
```

- The `--region` flag is required for the `assume-root` command, as the AWS global STS endpoint is not supported for this operation. If not provided, you will be prompted interactively (default: `us-east-1`).
- The CLI always uses the correct regional STS endpoint (e.g., `sts.us-east-1.amazonaws.com`).

Example (with region flag):

```bash
aws-priv-actions assume-root arn:aws:iam::123456789012:root IAMAuditRootUserCredentials --region us-east-1 --verbose
```

Example (interactive region prompt):

```bash
aws-priv-actions assume-root arn:aws:iam::123456789012:root IAMAuditRootUserCredentials
Enter the AWS region to use for STS (must be a regional endpoint) [us-east-1]:
```

### Available Task Policies

- `IAMAuditRootUserCredentials`: Audit root user credentials
- `IAMCreateRootUserPassword`: Create root user password
- `IAMDeleteRootUserCredentials`: Delete root user credentials
- `S3UnlockBucketPolicy`: Unlock S3 bucket policy
- `SQSUnlockQueuePolicy`: Unlock SQS queue policy

## Development

1. Clone the repository
2. Install UV (if not already installed):

   ```bash
   curl -LsSf https://astral.sh/uv/install.sh | sh
   ```

3. Install development dependencies:

   ```bash
   uv pip install -e .
   ```

4. Run tests:

   ```bash
   pytest
   ```

## License

MIT License
django-azure-ad-auth-redux 1.5.26
Authenticate users using Azure Active Directory.
Requires Python: <4,>=3.12
Keywords: Python, Active Directory, Django

Django Azure AD Auth Redux
==========================

*Django Azure AD Auth* allows you to authenticate through Azure Active Directory.

  This fork has the following additional features:
  - Add the specification of the decode algorithm per newer PyJWT requirements.
  - Supports django > 3.2.18

Installation
------------

Run `pip install django-azure-ad-auth-redux`

Add the `AzureActiveDirectoryBackend` to your `AUTHENTICATION_BACKENDS` setting:

```python
AUTHENTICATION_BACKENDS = (
    ...
    "azure_ad_auth.backends.AzureActiveDirectoryBackend",
)
```

Settings
--------

### AAD_TENANT_ID

The Azure Tenant ID. It can be found in the URL of the Azure Management Portal.

### AAD_CLIENT_ID

The Azure Application Client ID.

### AAD_AUTHORITY

**default:** `"https://login.microsoftonline.com"`
The domain that is used for authorization, the federation metadata document, and logging out.

### AAD_SCOPE

**default:** `"openid"`
OAuth scope parameter.

### AAD_RESPONSE_TYPE

**default:** `"id_token"`
Tells OAuth to return a JWT token in its response.

### AAD_RESPONSE_MODE

**default:** `"form_post"`
Defines how the response parameters are returned. Valid choices are `fragment` or `form_post`.

### AAD_USER_CREATION

**default:** `True`
Allow creation of new users after successful authentication.

### AAD_USER_MAPPING

**default:** `{}`
Map fields from the token to the user, to be used on creation.

### AAD_USER_STATIC_MAPPING

**default:** `{}`
Map static values to user fields on creation.

### AAD_GROUP_MAPPING

**default:** `{}`
Map group ids to group names for user permissions.