Skip to main content

A python-based pentesting library for Azure and Entra ID

Project description

Azure Offensive Library

A python-based pentesting library for Azure and Entra ID

Installation

Install the library using Python3 pip:

pip install azol

Basic Usage

Log in as a user and get all subscriptions:

from azol.credentials import User
from azol.clients import ArmClient

cred = User(username="user@domain.com")
arm_client = ArmClient(tenant="tenant.com", cred=cred)

subscriptions=arm_client.get_subscriptions()

for sub_id in subscriptions:
  print(sub_id)

Log in as a Service Principal and get all groups, with owners

from pprint import pprint
from azol.credentials import ServicePrincipal
from azol.clients import GraphClient

cred = ServicePrincipal(client_id="00000000-0000-0000-0000-000000000000", client_secret="your secret" )

graph_client = GraphClient(tenant="tenant.com", cred=cred)

groups=graph_client.get_all_groups_and_owners()

for group in groups:
  pprint(group)

Log in as a user to their default tenant, but use an interactive signin. Get all tenants the user belongs to.

from azol import *

cred=User("user@domain.com")
arm_client=ArmClient(cred=cred, oauth_flow="authorization_code")

tenants=arm_client.get_tenants()

for tenant in tenants:
  print(tenant["defaultDomain"])

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

azol-0.2.7.tar.gz (208.3 kB view details)

Uploaded Source

Built Distribution

azol-0.2.7-py3-none-any.whl (218.8 kB view details)

Uploaded Python 3

File details

Details for the file azol-0.2.7.tar.gz.

File metadata

  • Download URL: azol-0.2.7.tar.gz
  • Upload date:
  • Size: 208.3 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/5.1.1 CPython/3.12.7

File hashes

Hashes for azol-0.2.7.tar.gz
Algorithm Hash digest
SHA256 ad1935947b31fc278a6a49d1e94c16d8cb24f1c91cc661d18e64b6197770f9b6
MD5 495fbf65dbe984b4aaaad9899f28619b
BLAKE2b-256 b8467bcf212b865d5de2efe79dc5cc257a95e58413b5efef309d75f0e28a01ec

See more details on using hashes here.

File details

Details for the file azol-0.2.7-py3-none-any.whl.

File metadata

  • Download URL: azol-0.2.7-py3-none-any.whl
  • Upload date:
  • Size: 218.8 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/5.1.1 CPython/3.12.7

File hashes

Hashes for azol-0.2.7-py3-none-any.whl
Algorithm Hash digest
SHA256 c0d39d143ddc7cc74af9004579a2d51a78ad05b0ea9c833bd953c40a037e5320
MD5 13d604484e48799249fc009732e7921b
BLAKE2b-256 b268e710802be068ca5393628e0a74aedd9b8d81fdfdd0d385bb4eb355f0eec3

See more details on using hashes here.

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page