[Feature Request] Add Python module for Stealing Application Access Tokens
@terrancedejesus đang làm issue này rồi.
Từ ngày 10/5/2023.
Đánh giá
Issue này chưa được đánh giá.
Mô tả
🐍 Python Module for MITRE ATT&CK Technique
Tactic Name: Credential Access
Technique Name: Steal Application Access Token
Technique ID: T1528
Technique Description: Adversaries can steal application access tokens as a means of acquiring credentials to access remote systems and resources.
Describe the solution you'd like
A Application Access Token Stealing Module for use with a compromised GWS environment for Credential Access.
Requirements:
- Google Admin SDK API enabled
- Python packages (google-auth google-auth-oauthlib google-auth-httplib2 google-api-python-client, email, base64)
- Scopes (https://www.googleapis.com/auth/admin.directory.user)
Module Workflow:
Step 1: Collect all available Application Access Tokens
Module Actions:
1. Authenticate
2. Build the Directory API client
3. Retrieve the list of application access tokens
4. Print the access tokens
ChatGPT Example Script
from google.oauth2 import service_account
from googleapiclient.discovery import build
# replace with the path to your service account key file
KEY_FILE_LOCATION = '/path/to/service_account_key.json'
# replace with your customer ID
CUSTOMER_ID = 'my_customer'
# replace with your scope
SCOPE = 'https://www.googleapis.com/auth/admin.directory.group.member.readonly'
# create credentials from service account key file
credentials = service_account.Credentials.from_service_account_file(KEY_FILE_LOCATION, scopes=[SCOPE])
# build the Directory API client
directory_service = build('admin', 'directory_v1', credentials=credentials)
# retrieve the list of application access tokens
results = directory_service.tokens().list(customer=CUSTOMER_ID).execute()
# print the access tokens
for token in results.get('items', []):
print(token.get('applicationName'), token.get('kind'), token.get('clientId'), token.get('scopes'))
- Ngôn ngữ chính
- Python
- Star
- 171
- Fork
- 8
- Chỉ số merge pull request
- Không có pull request nào được merge trong 30 ngày
Chuẩn bị môi trường
- Không có Dockerfile hay tệp Docker Compose
- Không có mẫu pull request
- Đọc hướng dẫn đóng góp
Bắt đầu từ đâu
- Đọc hết issue, rồi đọc hướng dẫn đóng góp của dự án.
- Bình luận trên issue rằng bạn sẽ nhận — tránh hai người làm cùng một việc.
- Fork repository và làm thay đổi trên một nhánh.
- Mở pull request có tham chiếu số hiệu của issue.
Issue khác của elastic/SWAT
-
Dependency DashboardĐang mở
Độ khó 5/5 Hơn một tuần Mức phù hợp với người mới 15/100
-
bug
Độ khó 3/5 1-2 ngày Mức phù hợp với người mới 52/100
-
[Maintenance] Documentation Screenshots not RenderingCó thể làm lại được @terrancedejesus đã nhận 1153 ngày trước và không có pull request nào đang mở. Đang mởcommunity maintenance
-
[Feature Request] Create `add-emulation` commandCó thể làm lại được @brokensound77 đã nhận 1189 ngày trước và không có pull request nào đang mở. Đang mởenhancement
-
[Feature Request] Add Python module for detecting T1098.003 - Additional Cloud RolesCó thể làm lại được @terrancedejesus đã nhận 1258 ngày trước và không có pull request nào đang mở. Đang mởAPI: Admin enhancement Subtechnique: 003 Tactic: Persistence Technique: T1098
Issue tương tự
-
bug good first issue
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 78/100
yunaremaia/proto-drift#22 ·
-
bug good first issue
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 82/100
yunaremaia/memwatch#96 ·
-
bug good first issue
Độ khó 1/5 Dưới một giờ Mức phù hợp với người mới 91/100
yunaremaia/ci-gate-watch#34 ·
-
bug good first issue
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 85/100
yunaremaia/agent-capability-attestation#64 ·
Maintainer thường phản hồi trong vòng 1 ngày
-
bug good first issue
Độ khó 1/5 Dưới một giờ Mức phù hợp với người mới 86/100
yunaremaia/agent-call-graph#43 ·
Maintainer thường phản hồi trong vòng 1 ngày