pyiamvortex


Namepyiamvortex JSON
Version 0.3.1 PyPI version JSON
download
home_pagehttps://github.com/joelmccoy/pyiamvortex
Summary
upload_time2023-11-09 19:17:53
maintainer
docs_urlNone
authorJoel McCoy
requires_python>=3.9
licenseMIT
keywords iam aws parser
VCS
bugtrack_url
requirements No requirements were recorded.
Travis-CI No Travis.
coveralls test coverage No coveralls.
            # pyiamvortex
A python utility library used for getting all available AWS IAM actions and performing different operations on them.

## Summary
There is no available API to list out all of the available AWS IAM actions. This library uses the AWS Policy Generator to get all of the available actions and then parses them into a usable format.

Creating a `Vortex` is an operating environment where you initalize the backend of available AWS IAM actions in which you can perform different operations within this context.  The default backend is the AWS Policy Generator, but you can also create a `Vortex` with a custom backend.

This tool is useful for building AWS Least Privilege IAM policies.

## Install

```bash
pip install pyiamvortex
```

## Usage

### CLI

```bash
pyiamvortex get-aws-services # prints all available AWS services (i.e. ec2, s3, iam, etc.)
pyiamvortex get-aws-actions # prints all available AWS actions (i.e. ec2:DescribeInstances, s3:GetObject, etc.)
```

```bash
pyiamvortex get-aws-actions sts # prints all available AWS actions for the sts service
>>
[
    "sts:AssumeRole",
    "sts:AssumeRoleWithSAML",
    "sts:AssumeRoleWithWebIdentity",
    "sts:DecodeAuthorizationMessage",
    "sts:GetAccessKeyInfo",
    "sts:GetCallerIdentity",
    "sts:GetFederationToken",
    "sts:GetServiceBearerToken",
    "sts:GetSessionToken",
    "sts:SetSourceIdentity",
    "sts:TagSession"
]
```

```bash
pyiamvortex expand-aws-wildcard 'sts:AssumeRole*' # expands the wildcard to all available AWS actions that matches the pattern
>>
[
    "sts:AssumeRole",
    "sts:AssumeRoleWithSAML",
    "sts:AssumeRoleWithWebIdentity"
]
```

### Python Library

```python
from pyiamvortex import Vortex

vortex = Vortex() # initializes a vortex object with the default AWS actions map from AWS Policy Generator
print(vortex.get_aws_services()) # prints all available AWS services (i.e. ec2, s3, iam, etc.)
print(vortex.get_aws_actions()) # prints all available AWS actions (i.e. ec2:DescribeInstances, s3:GetObject, etc.)
print(vortex.get_aws_actions("s3")) # prints all available AWS actions for the s3 service (i.e. s3:GetObject, s3:PutObject, etc.)
```

            

Raw data

            {
    "_id": null,
    "home_page": "https://github.com/joelmccoy/pyiamvortex",
    "name": "pyiamvortex",
    "maintainer": "",
    "docs_url": null,
    "requires_python": ">=3.9",
    "maintainer_email": "",
    "keywords": "iam aws parser",
    "author": "Joel McCoy",
    "author_email": "\"nbajoel@gmail.com\"",
    "download_url": "https://files.pythonhosted.org/packages/21/01/665655e9de572d29d6820c1f12f7f4c185ac20019fba7bdcaf4ed1fe5bf8/pyiamvortex-0.3.1.tar.gz",
    "platform": null,
    "description": "# pyiamvortex\nA python utility library used for getting all available AWS IAM actions and performing different operations on them.\n\n## Summary\nThere is no available API to list out all of the available AWS IAM actions. This library uses the AWS Policy Generator to get all of the available actions and then parses them into a usable format.\n\nCreating a `Vortex` is an operating environment where you initalize the backend of available AWS IAM actions in which you can perform different operations within this context.  The default backend is the AWS Policy Generator, but you can also create a `Vortex` with a custom backend.\n\nThis tool is useful for building AWS Least Privilege IAM policies.\n\n## Install\n\n```bash\npip install pyiamvortex\n```\n\n## Usage\n\n### CLI\n\n```bash\npyiamvortex get-aws-services # prints all available AWS services (i.e. ec2, s3, iam, etc.)\npyiamvortex get-aws-actions # prints all available AWS actions (i.e. ec2:DescribeInstances, s3:GetObject, etc.)\n```\n\n```bash\npyiamvortex get-aws-actions sts # prints all available AWS actions for the sts service\n>>\n[\n    \"sts:AssumeRole\",\n    \"sts:AssumeRoleWithSAML\",\n    \"sts:AssumeRoleWithWebIdentity\",\n    \"sts:DecodeAuthorizationMessage\",\n    \"sts:GetAccessKeyInfo\",\n    \"sts:GetCallerIdentity\",\n    \"sts:GetFederationToken\",\n    \"sts:GetServiceBearerToken\",\n    \"sts:GetSessionToken\",\n    \"sts:SetSourceIdentity\",\n    \"sts:TagSession\"\n]\n```\n\n```bash\npyiamvortex expand-aws-wildcard 'sts:AssumeRole*' # expands the wildcard to all available AWS actions that matches the pattern\n>>\n[\n    \"sts:AssumeRole\",\n    \"sts:AssumeRoleWithSAML\",\n    \"sts:AssumeRoleWithWebIdentity\"\n]\n```\n\n### Python Library\n\n```python\nfrom pyiamvortex import Vortex\n\nvortex = Vortex() # initializes a vortex object with the default AWS actions map from AWS Policy Generator\nprint(vortex.get_aws_services()) # prints all available AWS services (i.e. ec2, s3, iam, etc.)\nprint(vortex.get_aws_actions()) # prints all available AWS actions (i.e. ec2:DescribeInstances, s3:GetObject, etc.)\nprint(vortex.get_aws_actions(\"s3\")) # prints all available AWS actions for the s3 service (i.e. s3:GetObject, s3:PutObject, etc.)\n```\n",
    "bugtrack_url": null,
    "license": "MIT",
    "summary": "",
    "version": "0.3.1",
    "project_urls": {
        "Changelog": "https://github.com/joelmccoy/pyiamvortex/blob/master/CHANGELOG.md",
        "Documentation": "https://github.com/joelmccoy/pyiamvortex/blob/master/README.md",
        "Homepage": "https://github.com/joelmccoy/pyiamvortex",
        "Issue tracker": "https://github.com/joelmccoy/pyiamvortex/issues"
    },
    "split_keywords": [
        "iam",
        "aws",
        "parser"
    ],
    "urls": [
        {
            "comment_text": "",
            "digests": {
                "blake2b_256": "f388227009824bbf327ed972e211687133241b97462cd3632893e0a8ef6473b3",
                "md5": "a83d3c97bef70ccb9302fd3e2a5c2786",
                "sha256": "d08181ce9a785c5b3021fa90d79dd32b05c2fedc4a623dbfe4d80ede83e20614"
            },
            "downloads": -1,
            "filename": "pyiamvortex-0.3.1-py3-none-any.whl",
            "has_sig": false,
            "md5_digest": "a83d3c97bef70ccb9302fd3e2a5c2786",
            "packagetype": "bdist_wheel",
            "python_version": "py3",
            "requires_python": ">=3.9",
            "size": 5068,
            "upload_time": "2023-11-09T19:17:51",
            "upload_time_iso_8601": "2023-11-09T19:17:51.682032Z",
            "url": "https://files.pythonhosted.org/packages/f3/88/227009824bbf327ed972e211687133241b97462cd3632893e0a8ef6473b3/pyiamvortex-0.3.1-py3-none-any.whl",
            "yanked": false,
            "yanked_reason": null
        },
        {
            "comment_text": "",
            "digests": {
                "blake2b_256": "2101665655e9de572d29d6820c1f12f7f4c185ac20019fba7bdcaf4ed1fe5bf8",
                "md5": "3f2ec0a66d0a9e4c30ec47895e61a290",
                "sha256": "53af433c18c0ea12dbdc785661a5011e030331250cd4404125f5de3d7078b4d5"
            },
            "downloads": -1,
            "filename": "pyiamvortex-0.3.1.tar.gz",
            "has_sig": false,
            "md5_digest": "3f2ec0a66d0a9e4c30ec47895e61a290",
            "packagetype": "sdist",
            "python_version": "source",
            "requires_python": ">=3.9",
            "size": 5348,
            "upload_time": "2023-11-09T19:17:53",
            "upload_time_iso_8601": "2023-11-09T19:17:53.204978Z",
            "url": "https://files.pythonhosted.org/packages/21/01/665655e9de572d29d6820c1f12f7f4c185ac20019fba7bdcaf4ed1fe5bf8/pyiamvortex-0.3.1.tar.gz",
            "yanked": false,
            "yanked_reason": null
        }
    ],
    "upload_time": "2023-11-09 19:17:53",
    "github": true,
    "gitlab": false,
    "bitbucket": false,
    "codeberg": false,
    "github_user": "joelmccoy",
    "github_project": "pyiamvortex",
    "travis_ci": false,
    "coveralls": false,
    "github_actions": true,
    "lcname": "pyiamvortex"
}
        
Elapsed time: 0.16543s