bt-cli 0.4.7__tar.gz

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (170) hide show
  1. bt_cli-0.4.7/.claude/settings.local.json +128 -0
  2. bt_cli-0.4.7/.claude/skills/bt/SKILL.md +98 -0
  3. bt_cli-0.4.7/.claude/skills/entitle/SKILL.md +159 -0
  4. bt_cli-0.4.7/.claude/skills/epmw/SKILL.md +145 -0
  5. bt_cli-0.4.7/.claude/skills/pra/SKILL.md +149 -0
  6. bt_cli-0.4.7/.claude/skills/pws/SKILL.md +197 -0
  7. bt_cli-0.4.7/.env.example +58 -0
  8. bt_cli-0.4.7/.github/workflows/ci.yml +115 -0
  9. bt_cli-0.4.7/.github/workflows/release.yml +253 -0
  10. bt_cli-0.4.7/.gitignore +44 -0
  11. bt_cli-0.4.7/CLAUDE.md +94 -0
  12. bt_cli-0.4.7/PKG-INFO +172 -0
  13. bt_cli-0.4.7/README.md +128 -0
  14. bt_cli-0.4.7/assets/cli-help.png +0 -0
  15. bt_cli-0.4.7/assets/cli-output.png +0 -0
  16. bt_cli-0.4.7/bt-admin.spec +128 -0
  17. bt_cli-0.4.7/bt.spec +57 -0
  18. bt_cli-0.4.7/bt_entry.py +18 -0
  19. bt_cli-0.4.7/pyproject.toml +74 -0
  20. bt_cli-0.4.7/scripts/bt_entry.py +9 -0
  21. bt_cli-0.4.7/src/bt_cli/__init__.py +3 -0
  22. bt_cli-0.4.7/src/bt_cli/cli.py +830 -0
  23. bt_cli-0.4.7/src/bt_cli/commands/__init__.py +1 -0
  24. bt_cli-0.4.7/src/bt_cli/commands/configure.py +415 -0
  25. bt_cli-0.4.7/src/bt_cli/commands/learn.py +229 -0
  26. bt_cli-0.4.7/src/bt_cli/commands/quick.py +784 -0
  27. bt_cli-0.4.7/src/bt_cli/core/__init__.py +1 -0
  28. bt_cli-0.4.7/src/bt_cli/core/auth.py +213 -0
  29. bt_cli-0.4.7/src/bt_cli/core/client.py +313 -0
  30. bt_cli-0.4.7/src/bt_cli/core/config.py +393 -0
  31. bt_cli-0.4.7/src/bt_cli/core/config_file.py +420 -0
  32. bt_cli-0.4.7/src/bt_cli/core/csv_utils.py +91 -0
  33. bt_cli-0.4.7/src/bt_cli/core/errors.py +247 -0
  34. bt_cli-0.4.7/src/bt_cli/core/output.py +205 -0
  35. bt_cli-0.4.7/src/bt_cli/core/prompts.py +87 -0
  36. bt_cli-0.4.7/src/bt_cli/core/rest_debug.py +221 -0
  37. bt_cli-0.4.7/src/bt_cli/data/CLAUDE.md +88 -0
  38. bt_cli-0.4.7/src/bt_cli/data/__init__.py +0 -0
  39. bt_cli-0.4.7/src/bt_cli/data/skills/bt/SKILL.md +98 -0
  40. bt_cli-0.4.7/src/bt_cli/data/skills/entitle/SKILL.md +159 -0
  41. bt_cli-0.4.7/src/bt_cli/data/skills/epmw/SKILL.md +145 -0
  42. bt_cli-0.4.7/src/bt_cli/data/skills/pra/SKILL.md +149 -0
  43. bt_cli-0.4.7/src/bt_cli/data/skills/pws/SKILL.md +197 -0
  44. bt_cli-0.4.7/src/bt_cli/entitle/__init__.py +1 -0
  45. bt_cli-0.4.7/src/bt_cli/entitle/client/__init__.py +5 -0
  46. bt_cli-0.4.7/src/bt_cli/entitle/client/base.py +443 -0
  47. bt_cli-0.4.7/src/bt_cli/entitle/commands/__init__.py +24 -0
  48. bt_cli-0.4.7/src/bt_cli/entitle/commands/accounts.py +53 -0
  49. bt_cli-0.4.7/src/bt_cli/entitle/commands/applications.py +39 -0
  50. bt_cli-0.4.7/src/bt_cli/entitle/commands/auth.py +68 -0
  51. bt_cli-0.4.7/src/bt_cli/entitle/commands/bundles.py +218 -0
  52. bt_cli-0.4.7/src/bt_cli/entitle/commands/integrations.py +60 -0
  53. bt_cli-0.4.7/src/bt_cli/entitle/commands/permissions.py +70 -0
  54. bt_cli-0.4.7/src/bt_cli/entitle/commands/policies.py +97 -0
  55. bt_cli-0.4.7/src/bt_cli/entitle/commands/resources.py +131 -0
  56. bt_cli-0.4.7/src/bt_cli/entitle/commands/roles.py +74 -0
  57. bt_cli-0.4.7/src/bt_cli/entitle/commands/users.py +123 -0
  58. bt_cli-0.4.7/src/bt_cli/entitle/commands/workflows.py +187 -0
  59. bt_cli-0.4.7/src/bt_cli/entitle/models/__init__.py +31 -0
  60. bt_cli-0.4.7/src/bt_cli/entitle/models/bundle.py +28 -0
  61. bt_cli-0.4.7/src/bt_cli/entitle/models/common.py +37 -0
  62. bt_cli-0.4.7/src/bt_cli/entitle/models/integration.py +30 -0
  63. bt_cli-0.4.7/src/bt_cli/entitle/models/permission.py +27 -0
  64. bt_cli-0.4.7/src/bt_cli/entitle/models/policy.py +25 -0
  65. bt_cli-0.4.7/src/bt_cli/entitle/models/resource.py +29 -0
  66. bt_cli-0.4.7/src/bt_cli/entitle/models/role.py +28 -0
  67. bt_cli-0.4.7/src/bt_cli/entitle/models/user.py +24 -0
  68. bt_cli-0.4.7/src/bt_cli/entitle/models/workflow.py +55 -0
  69. bt_cli-0.4.7/src/bt_cli/epmw/__init__.py +1 -0
  70. bt_cli-0.4.7/src/bt_cli/epmw/client/__init__.py +5 -0
  71. bt_cli-0.4.7/src/bt_cli/epmw/client/base.py +848 -0
  72. bt_cli-0.4.7/src/bt_cli/epmw/commands/__init__.py +33 -0
  73. bt_cli-0.4.7/src/bt_cli/epmw/commands/audits.py +250 -0
  74. bt_cli-0.4.7/src/bt_cli/epmw/commands/auth.py +55 -0
  75. bt_cli-0.4.7/src/bt_cli/epmw/commands/computers.py +140 -0
  76. bt_cli-0.4.7/src/bt_cli/epmw/commands/events.py +233 -0
  77. bt_cli-0.4.7/src/bt_cli/epmw/commands/groups.py +215 -0
  78. bt_cli-0.4.7/src/bt_cli/epmw/commands/policies.py +673 -0
  79. bt_cli-0.4.7/src/bt_cli/epmw/commands/quick.py +348 -0
  80. bt_cli-0.4.7/src/bt_cli/epmw/commands/requests.py +224 -0
  81. bt_cli-0.4.7/src/bt_cli/epmw/commands/roles.py +78 -0
  82. bt_cli-0.4.7/src/bt_cli/epmw/commands/tasks.py +38 -0
  83. bt_cli-0.4.7/src/bt_cli/epmw/commands/users.py +219 -0
  84. bt_cli-0.4.7/src/bt_cli/epmw/models/__init__.py +1 -0
  85. bt_cli-0.4.7/src/bt_cli/pra/__init__.py +1 -0
  86. bt_cli-0.4.7/src/bt_cli/pra/client/__init__.py +5 -0
  87. bt_cli-0.4.7/src/bt_cli/pra/client/base.py +618 -0
  88. bt_cli-0.4.7/src/bt_cli/pra/commands/__init__.py +30 -0
  89. bt_cli-0.4.7/src/bt_cli/pra/commands/auth.py +55 -0
  90. bt_cli-0.4.7/src/bt_cli/pra/commands/import_export.py +442 -0
  91. bt_cli-0.4.7/src/bt_cli/pra/commands/jump_clients.py +139 -0
  92. bt_cli-0.4.7/src/bt_cli/pra/commands/jump_groups.py +146 -0
  93. bt_cli-0.4.7/src/bt_cli/pra/commands/jump_items.py +638 -0
  94. bt_cli-0.4.7/src/bt_cli/pra/commands/jumpoints.py +95 -0
  95. bt_cli-0.4.7/src/bt_cli/pra/commands/policies.py +197 -0
  96. bt_cli-0.4.7/src/bt_cli/pra/commands/quick.py +470 -0
  97. bt_cli-0.4.7/src/bt_cli/pra/commands/teams.py +81 -0
  98. bt_cli-0.4.7/src/bt_cli/pra/commands/users.py +87 -0
  99. bt_cli-0.4.7/src/bt_cli/pra/commands/vault.py +564 -0
  100. bt_cli-0.4.7/src/bt_cli/pra/models/__init__.py +27 -0
  101. bt_cli-0.4.7/src/bt_cli/pra/models/common.py +12 -0
  102. bt_cli-0.4.7/src/bt_cli/pra/models/jump_client.py +25 -0
  103. bt_cli-0.4.7/src/bt_cli/pra/models/jump_group.py +15 -0
  104. bt_cli-0.4.7/src/bt_cli/pra/models/jump_item.py +72 -0
  105. bt_cli-0.4.7/src/bt_cli/pra/models/jumpoint.py +19 -0
  106. bt_cli-0.4.7/src/bt_cli/pra/models/team.py +14 -0
  107. bt_cli-0.4.7/src/bt_cli/pra/models/user.py +17 -0
  108. bt_cli-0.4.7/src/bt_cli/pra/models/vault.py +45 -0
  109. bt_cli-0.4.7/src/bt_cli/pws/__init__.py +1 -0
  110. bt_cli-0.4.7/src/bt_cli/pws/client/__init__.py +5 -0
  111. bt_cli-0.4.7/src/bt_cli/pws/client/base.py +356 -0
  112. bt_cli-0.4.7/src/bt_cli/pws/client/beyondinsight.py +869 -0
  113. bt_cli-0.4.7/src/bt_cli/pws/client/passwordsafe.py +1786 -0
  114. bt_cli-0.4.7/src/bt_cli/pws/commands/__init__.py +33 -0
  115. bt_cli-0.4.7/src/bt_cli/pws/commands/accounts.py +372 -0
  116. bt_cli-0.4.7/src/bt_cli/pws/commands/assets.py +311 -0
  117. bt_cli-0.4.7/src/bt_cli/pws/commands/auth.py +166 -0
  118. bt_cli-0.4.7/src/bt_cli/pws/commands/clouds.py +221 -0
  119. bt_cli-0.4.7/src/bt_cli/pws/commands/config.py +344 -0
  120. bt_cli-0.4.7/src/bt_cli/pws/commands/credentials.py +347 -0
  121. bt_cli-0.4.7/src/bt_cli/pws/commands/databases.py +306 -0
  122. bt_cli-0.4.7/src/bt_cli/pws/commands/directories.py +199 -0
  123. bt_cli-0.4.7/src/bt_cli/pws/commands/functional.py +298 -0
  124. bt_cli-0.4.7/src/bt_cli/pws/commands/import_export.py +452 -0
  125. bt_cli-0.4.7/src/bt_cli/pws/commands/platforms.py +118 -0
  126. bt_cli-0.4.7/src/bt_cli/pws/commands/quick.py +1646 -0
  127. bt_cli-0.4.7/src/bt_cli/pws/commands/search.py +256 -0
  128. bt_cli-0.4.7/src/bt_cli/pws/commands/secrets.py +1343 -0
  129. bt_cli-0.4.7/src/bt_cli/pws/commands/systems.py +389 -0
  130. bt_cli-0.4.7/src/bt_cli/pws/commands/users.py +415 -0
  131. bt_cli-0.4.7/src/bt_cli/pws/commands/workgroups.py +166 -0
  132. bt_cli-0.4.7/src/bt_cli/pws/config.py +18 -0
  133. bt_cli-0.4.7/src/bt_cli/pws/models/__init__.py +19 -0
  134. bt_cli-0.4.7/src/bt_cli/pws/models/account.py +186 -0
  135. bt_cli-0.4.7/src/bt_cli/pws/models/asset.py +102 -0
  136. bt_cli-0.4.7/src/bt_cli/pws/models/common.py +132 -0
  137. bt_cli-0.4.7/src/bt_cli/pws/models/system.py +121 -0
  138. bt_cli-0.4.7/tests/__init__.py +1 -0
  139. bt_cli-0.4.7/tests/conftest.py +228 -0
  140. bt_cli-0.4.7/tests/core/__init__.py +1 -0
  141. bt_cli-0.4.7/tests/core/test_auth.py +301 -0
  142. bt_cli-0.4.7/tests/core/test_config.py +434 -0
  143. bt_cli-0.4.7/tests/core/test_errors.py +289 -0
  144. bt_cli-0.4.7/tests/core/test_rest_debug.py +264 -0
  145. bt_cli-0.4.7/tests/entitle/__init__.py +1 -0
  146. bt_cli-0.4.7/tests/entitle/test_client.py +610 -0
  147. bt_cli-0.4.7/tests/entitle/test_commands.py +590 -0
  148. bt_cli-0.4.7/tests/entitle-smoke-test.sh +42 -0
  149. bt_cli-0.4.7/tests/epmw/__init__.py +1 -0
  150. bt_cli-0.4.7/tests/epmw/test_client.py +353 -0
  151. bt_cli-0.4.7/tests/epmw/test_commands.py +326 -0
  152. bt_cli-0.4.7/tests/epmw-quick-test-plan.md +177 -0
  153. bt_cli-0.4.7/tests/fixtures/__init__.py +3 -0
  154. bt_cli-0.4.7/tests/fixtures/responses.py +528 -0
  155. bt_cli-0.4.7/tests/integration/__init__.py +5 -0
  156. bt_cli-0.4.7/tests/integration/conftest.py +96 -0
  157. bt_cli-0.4.7/tests/integration/test_entitle_integration.py +89 -0
  158. bt_cli-0.4.7/tests/integration/test_epmw_integration.py +141 -0
  159. bt_cli-0.4.7/tests/integration/test_pra_integration.py +75 -0
  160. bt_cli-0.4.7/tests/integration/test_pws_integration.py +85 -0
  161. bt_cli-0.4.7/tests/pra/__init__.py +0 -0
  162. bt_cli-0.4.7/tests/pra/test_client.py +506 -0
  163. bt_cli-0.4.7/tests/pra/test_commands.py +367 -0
  164. bt_cli-0.4.7/tests/pra-smoke-test.sh +58 -0
  165. bt_cli-0.4.7/tests/pra-test-plan.md +595 -0
  166. bt_cli-0.4.7/tests/pws/__init__.py +0 -0
  167. bt_cli-0.4.7/tests/pws/test_client.py +336 -0
  168. bt_cli-0.4.7/tests/pws/test_commands.py +313 -0
  169. bt_cli-0.4.7/tests/pws-quick-test-plan.md +279 -0
  170. bt_cli-0.4.7/tests/pws-smoke-test.sh +57 -0
@@ -0,0 +1,128 @@
1
+ {
2
+ "permissions": {
3
+ "allow": [
4
+ "Bash(tree:*)",
5
+ "Bash(wc:*)",
6
+ "Bash(source .venv/bin/activate)",
7
+ "Bash(source:*)",
8
+ "Bash(bt --profile default pws auth:*)",
9
+ "Bash(git add:*)",
10
+ "Bash(git commit:*)",
11
+ "Bash(git push:*)",
12
+ "Bash(pip install:*)",
13
+ "Bash(bt pws auth:*)",
14
+ "Bash(bt epmw auth test:*)",
15
+ "Bash(bt epmw events --help:*)",
16
+ "Bash(bt epmw events list:*)",
17
+ "Bash(bt epmw requests list:*)",
18
+ "Bash(ls:*)",
19
+ "Bash(bt --show-rest pws auth:*)",
20
+ "Bash(bt --show-rest entitle auth test:*)",
21
+ "Bash(pytest:*)",
22
+ "Bash(python -m pytest:*)",
23
+ "Bash(set -a)",
24
+ "Bash(set +a)",
25
+ "Bash(grep:*)",
26
+ "Bash(python3 -m pip check:*)",
27
+ "Bash(bt pws credentials checkin:*)",
28
+ "Bash(bt pws accounts list --help:*)",
29
+ "Bash(bt pws accounts list:*)",
30
+ "Bash(python3:*)",
31
+ "Bash(bt pws accounts get:*)",
32
+ "Bash(bt pws quick --help:*)",
33
+ "Bash(bt pws quick checkout:*)",
34
+ "Bash(bt pws quick checkin:*)",
35
+ "Bash(bt pws:*)",
36
+ "Bash(bt epmw computers list:*)",
37
+ "Bash(bt epmw quick status:*)",
38
+ "Bash(bt pra quick --help:*)",
39
+ "Bash(bt epmw quick --help:*)",
40
+ "Bash(bt pra:*)",
41
+ "Bash(bt epmw quick stale:*)",
42
+ "Bash(git config:*)",
43
+ "Bash(GIT_TERMINAL_PROMPT=0 git -c credential.helper= push https://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@github.com/BTSolution-Engineering/btcli.git master)",
44
+ "Bash(bt entitle bundles list:*)",
45
+ "Bash(bt entitle bundles get:*)",
46
+ "Bash(bt --show-rest entitle bundles get:*)",
47
+ "Bash(bt entitle workflows list:*)",
48
+ "Bash(bt entitle users list:*)",
49
+ "Bash(bt entitle integrations list:*)",
50
+ "Bash(bt entitle workflows get:*)",
51
+ "Bash(bt entitle resources list:*)",
52
+ "Bash(bt entitle roles list:*)",
53
+ "Bash(bt entitle permissions:*)",
54
+ "Bash(bt entitle policies list:*)",
55
+ "Bash(bt entitle accounts list:*)",
56
+ "Bash(bt entitle:*)",
57
+ "Bash(bt epmw groups list:*)",
58
+ "Bash(bt epmw policies list:*)",
59
+ "Bash(bt epmw users list:*)",
60
+ "Bash(bt epmw roles list:*)",
61
+ "Bash(bt epmw policies --help:*)",
62
+ "Bash(bt epmw policies appgroups list:*)",
63
+ "Bash(BT_DEBUG=1 bt epmw:*)",
64
+ "Bash(echo:*)",
65
+ "Bash(bt epmw policies groups:*)",
66
+ "Bash(bt epmw policies download:*)",
67
+ "Bash(bt --help:*)",
68
+ "Bash(bt context:*)",
69
+ "Bash(bt docs:*)",
70
+ "Bash(bt learn --help:*)",
71
+ "Bash(bt learn add:*)",
72
+ "Bash(bt learn clear:*)",
73
+ "Bash(bt epmw policies revisions list:*)",
74
+ "Bash(bt whoami:*)",
75
+ "Bash(__NEW_LINE_05222021dc21be1a__ echo \"=== Testing Dry-Run Imports ===\")",
76
+ "Bash(__NEW_LINE_05222021dc21be1a__ echo \"\")",
77
+ "Bash(jq '.[] | select\\(.SystemName | contains\\(\"\"\"\"csv-import-test\"\"\"\"\\)\\)' __NEW_LINE_d68138bce5e86b8b__ echo \"\" echo \"=== Verify Accounts Were Created ===\" bt pws accounts list -o json)",
78
+ "Bash(jq '.[] | select\\(.SystemName | contains\\(\"\"\"\"csv-import-test\"\"\"\"\\)\\)' __NEW_LINE_d68138bce5e86b8b__ echo \"\" echo \"=== Cleaning Up Test System ===\" bt pws quick offboard -s \"csv-import-test-01\" --force)",
79
+ "Bash(bt epmw --help:*)",
80
+ "WebFetch(domain:docs.beyondtrust.com)",
81
+ "Bash(git remote set-url:*)",
82
+ "Bash(bt version:*)",
83
+ "Bash(bt epmw computers delete:*)",
84
+ "Bash(bt epmw:*)",
85
+ "Bash(find:*)",
86
+ "Bash(bt skills:*)",
87
+ "Bash(aws sts get-caller-identity:*)",
88
+ "Bash(aws iam list-attached-user-policies:*)",
89
+ "Bash(aws iam get-user:*)",
90
+ "Bash(aws ec2 describe-instances:*)",
91
+ "Bash(aws ec2 run-instances:*)",
92
+ "Bash(clear)",
93
+ "Bash(bt quick --help:*)",
94
+ "Bash(bt quick:*)",
95
+ "Bash(aws ec2 wait:*)",
96
+ "Bash(jq -r \".[] | select\\(.SystemName | test\\(\"\"axion\"\"\\)\\) | \"\"\\\\\\(.SystemName\\)\\\\t\\\\\\(.IPAddress\\)\\\\tFA:\\\\\\(.FunctionalAccountID\\)\"\"\" __NEW_LINE_403e7a2c58439d4f__ echo echo '=== PRA - Axion Jump Items ===' bt pra jump-items shell list -o json)",
97
+ "Bash(env)",
98
+ "Bash(aws ec2 terminate-instances:*)",
99
+ "Bash(GIT_TERMINAL_PROMPT=0 git push:*)",
100
+ "Bash(sshpass -p 'Passgo123!' ssh -o StrictHostKeyChecking=no admin@192.168.100.132 'curl -s -X POST -d \"\"grant_type=client_credentials&client_id=d3b50b99-1650-4ddb-b00b-7fc27b963976&client_secret=/tUEmXpUrfy4K71Cqx29XemZomNCkWogYvLs5r0w9m8=\"\" \"\"https://semcp.ps-dev.beyondtrustcloud.com/BeyondTrust/api/public/v3/Auth/connect/token\"\"')",
101
+ "Bash(sshpass -p 'Passgo123!' ssh -o StrictHostKeyChecking=no -o PreferredAuthentications=password admin@192.168.100.132 'echo connected')",
102
+ "Bash(SSHPASS='Passgo123!' sshpass -e ssh -o StrictHostKeyChecking=no admin@192.168.100.132 'echo connected')",
103
+ "Bash(ssh:*)",
104
+ "Bash(REST_DEBUG=1 bt pws:*)",
105
+ "Bash(bt --debug-rest pws functional create:*)",
106
+ "Bash(bt --show-rest pws functional create:*)",
107
+ "Bash(bt:*)",
108
+ "Bash(git tag:*)",
109
+ "Bash(gh run list:*)",
110
+ "Bash(python:*)",
111
+ "Bash(pyinstaller:*)",
112
+ "Bash(gh release list:*)",
113
+ "Bash(./dist/bt:*)",
114
+ "Bash(if [ -n \"$GH_TOKEN\" ])",
115
+ "Bash([ -n \"$GITHUB_TOKEN\" ])",
116
+ "Bash(then echo \"Token found\")",
117
+ "Bash(else echo \"No GH token in .env - checking git credentials\")",
118
+ "Bash(fi)",
119
+ "Bash(export GH_TOKEN=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)",
120
+ "Bash(gh release:*)",
121
+ "Bash(gh release delete:*)",
122
+ "Bash(pip show:*)",
123
+ "Bash(unset:*)",
124
+ "Bash(git mv:*)",
125
+ "Bash(twine upload:*)"
126
+ ]
127
+ }
128
+ }
@@ -0,0 +1,98 @@
1
+ ---
2
+ name: bt
3
+ description: BeyondTrust platform CLI cross-product commands. Use when working across PWS, PRA, Entitle, or EPMW together, or for PASM workflows combining Password Safe and PRA.
4
+ ---
5
+
6
+ # BT-Admin Cross-Product Commands
7
+
8
+ CLI for BeyondTrust platform: Password Safe, PRA, Entitle, EPM Windows.
9
+
10
+ ## IMPORTANT: Destructive Operations
11
+
12
+ **ALWAYS confirm with the user before running destructive commands:**
13
+ - `delete` - Removes resources permanently
14
+ - `offboard` - Removes systems/accounts from management
15
+ - `archive` - Archives computers (EPMW)
16
+ - `revoke` - Revokes permissions (Entitle)
17
+
18
+ Before executing any destructive operation:
19
+ 1. List what will be affected
20
+ 2. Ask user for explicit confirmation
21
+ 3. Never use `--force` flag without user approval
22
+
23
+ ## Setup
24
+
25
+ ```bash
26
+ cd /home/admin/entitl-sko/bt-cli
27
+ source .venv/bin/activate && source .env
28
+ ```
29
+
30
+ ## Test All Connections
31
+
32
+ ```bash
33
+ bt whoami # Test all configured products
34
+ bt whoami -o json # JSON output
35
+ ```
36
+
37
+ ## Cross-Product Quick Commands (`bt quick`)
38
+
39
+ ### PASM Search (PWS + PRA)
40
+ Find systems/accounts across both products. Shows ECM alignment (names must match for credential injection).
41
+
42
+ ```bash
43
+ bt quick pasm-search axion
44
+ bt quick pasm-search web-server -o json
45
+ ```
46
+
47
+ ### PASM Onboard (PWS + PRA)
48
+ Onboard a host to both Password Safe and PRA in one command.
49
+
50
+ ```bash
51
+ # Linux SSH host
52
+ bt quick pasm-onboard -n "my-server" -i "10.0.1.50" -w 3 -j 3 -g 24
53
+
54
+ # Full options
55
+ bt quick pasm-onboard \
56
+ --name "web-01" \
57
+ --ip "10.0.1.100" \
58
+ --workgroup 3 \
59
+ --jumpoint 3 \
60
+ --jump-group 24 \
61
+ --functional-account 7 \
62
+ --elevation "sudo" \
63
+ --pra-username "ec2-admin"
64
+
65
+ # Windows RDP host
66
+ bt quick pasm-onboard -n "win-srv" -i "10.0.2.10" -w 2 -p 1 -j 3 -g 31 --jump-type rdp --port 3389
67
+
68
+ # Skip one product
69
+ bt quick pasm-onboard -n "pra-only" -i "10.0.1.5" -j 3 -g 24 --skip-pws
70
+ bt quick pasm-onboard -n "pws-only" -i "10.0.1.6" -w 3 --skip-pra
71
+ ```
72
+
73
+ ### PASM Offboard
74
+ Remove from both products.
75
+
76
+ ```bash
77
+ bt quick pasm-offboard -n "my-server"
78
+ bt quick pasm-offboard -n "web-01" --force
79
+ ```
80
+
81
+ ## Environment Reference IDs
82
+
83
+ | Resource | ID | Notes |
84
+ |----------|-----|-------|
85
+ | PWS Workgroup (AWS) | 3 | AWS_Account Workgroup |
86
+ | PWS Workgroup (Datacenter) | 2 | Datacenter_West |
87
+ | PWS Functional Account | 7 | pws-functional SSH key |
88
+ | PWS Platform Linux | 2 | |
89
+ | PWS Platform Windows | 1 | |
90
+ | PRA Jumpoint (AWS) | 3 | AWS Account |
91
+ | PRA Jumpoint (Datacenter) | 2 | Data Center 01 |
92
+ | PRA Vault Account (ec2-admin) | 31 | SSH CA for EC2 |
93
+ | Entitle PRA Integration | bb2a3c79-02a9-45d9-be7f-f209d97cb1d7 | |
94
+ | Entitle Customer Access | 22f4960f-b2ee-435f-9fa2-b82baeca06b2 | Virtual integration |
95
+
96
+ ## Product-Specific Skills
97
+
98
+ Use `/pws`, `/pra`, `/entitle`, `/epmw` for product-specific commands.
@@ -0,0 +1,159 @@
1
+ ---
2
+ name: entitle
3
+ description: Entitle commands for JIT access, bundles, workflows, and permissions. Use when working with access requests, approval workflows, or managing user entitlements.
4
+ ---
5
+
6
+ # Entitle Commands (`bt entitle`)
7
+
8
+ ## IMPORTANT: Destructive Operations
9
+
10
+ **ALWAYS confirm with the user before:**
11
+ - `bt entitle resources delete` - Deletes resource from integration
12
+ - `bt entitle bundles delete` - Deletes access bundle
13
+ - `bt entitle permissions revoke` - Revokes active permission
14
+
15
+ List affected resources first, then ask for explicit confirmation.
16
+
17
+ ## Integrations & Resources
18
+
19
+ ```bash
20
+ # List integrations (connected apps)
21
+ bt entitle integrations list
22
+ bt entitle integrations get <integration_id>
23
+
24
+ # List resources in an integration
25
+ bt entitle resources list --integration <integration_id>
26
+ bt entitle resources get <resource_id>
27
+
28
+ # Virtual integration resources
29
+ bt entitle resources create-virtual \
30
+ --name "Customer-05 (Bing7)" \
31
+ --integration 22f4960f-b2ee-435f-9fa2-b82baeca06b2 \
32
+ --source-role-id <role_id> \
33
+ --role-name "Start Session"
34
+ bt entitle resources delete <resource_id>
35
+ ```
36
+
37
+ ## Bundles
38
+
39
+ Access bundles group multiple roles across integrations.
40
+
41
+ ```bash
42
+ bt entitle bundles list
43
+ bt entitle bundles get <bundle_id>
44
+ bt entitle bundles create \
45
+ --name "Dev AWS Access" \
46
+ --description "Development AWS console access" \
47
+ --workflow <workflow_id> \
48
+ --role <role_id> \
49
+ --duration 3600
50
+ bt entitle bundles delete <bundle_id>
51
+ ```
52
+
53
+ ## Workflows
54
+
55
+ ```bash
56
+ bt entitle workflows list
57
+ bt entitle workflows get <workflow_id>
58
+ ```
59
+
60
+ **Available Workflows:**
61
+ | Name | Type | Use Case |
62
+ |------|------|----------|
63
+ | Auto Approve | Automatic | Requests <= 12 hours |
64
+ | Low sensitivity | Simple | Single approver |
65
+ | Medium Sensitivity | Standard | Standard approval |
66
+ | Production access | Multi-step | Duration-based tiers |
67
+
68
+ ## Users & Permissions
69
+
70
+ ```bash
71
+ # Users
72
+ bt entitle users list
73
+ bt entitle users get <user_id>
74
+
75
+ # Active permissions
76
+ bt entitle permissions list
77
+ bt entitle permissions list --user <user_id>
78
+ bt entitle permissions revoke <permission_id>
79
+
80
+ # Accounts
81
+ bt entitle accounts list --integration <integration_id>
82
+ ```
83
+
84
+ ## Roles & Policies
85
+
86
+ ```bash
87
+ bt entitle roles list
88
+ bt entitle roles list --resource <resource_id>
89
+ bt entitle roles get <role_id>
90
+
91
+ bt entitle policies list
92
+ bt entitle policies get <policy_id>
93
+ ```
94
+
95
+ ## Common Workflows
96
+
97
+ ### Add PRA Jump Group to Entitle
98
+
99
+ **Important:** PRA integration sync is **asynchronous** (runs hourly). After creating a new PRA jump group, either:
100
+ - Wait up to 1 hour for auto-sync
101
+ - Or manually trigger sync in Entitle UI: Integrations → PRA → Sync Now
102
+
103
+ ```bash
104
+ # 1. Trigger PRA sync in Entitle UI (or wait for hourly sync)
105
+
106
+ # 2. Find the new PRA resource
107
+ bt entitle resources list --integration bb2a3c79-02a9-45d9-be7f-f209d97cb1d7
108
+
109
+ # 3. Get "Start Sessions Only" role ID
110
+ bt entitle roles list --resource <pra_resource_id>
111
+
112
+ # 4. Add to Customer Access virtual integration
113
+ bt entitle resources create-virtual \
114
+ --name "Customer-05" \
115
+ --integration 22f4960f-b2ee-435f-9fa2-b82baeca06b2 \
116
+ --source-role-id <role_id> \
117
+ --role-name "Start Session"
118
+ ```
119
+
120
+ ### Check User Access
121
+
122
+ ```bash
123
+ bt entitle permissions list --user "user@example.com" -o json
124
+ ```
125
+
126
+ ## Key IDs
127
+
128
+ | Resource | ID |
129
+ |----------|-----|
130
+ | PRA Integration | bb2a3c79-02a9-45d9-be7f-f209d97cb1d7 |
131
+ | Customer Access (Virtual) | 22f4960f-b2ee-435f-9fa2-b82baeca06b2 |
132
+ | AWS SandBox | (check `bt entitle integrations list`) |
133
+
134
+ ## Integrations Available
135
+
136
+ - Cloud10 (Virtual Application)
137
+ - NexusDyn - Azure
138
+ - Customer Access (Virtual)
139
+ - Privileged Remote Access (PRA)
140
+ - AWS - SandBox Account
141
+ - Nexusdyn - Postgres ERP Database
142
+ - NexusDyn - EntraID
143
+
144
+ ## Supported Applications (75+)
145
+
146
+ **Cloud:** AWS, Azure, GCP, Oracle OCI
147
+ **Identity:** Okta, Entra ID, OneLogin, JumpCloud
148
+ **DevOps:** GitHub, GitLab, Jenkins, Terraform Cloud
149
+ **Databases:** Postgres, MySQL, MSSQL, MongoDB, Snowflake
150
+ **Kubernetes:** EKS, AKS, GKE, Rancher
151
+ **BeyondTrust:** Password Safe, PRA, Remote Support
152
+
153
+ ## API Notes
154
+
155
+ - Base path: `/public/v1`
156
+ - Pagination: `page`/`perPage`
157
+ - Response: `{"result": [...], "pagination": {...}}`
158
+ - All IDs are UUIDs (strings)
159
+ - Bearer token auth
@@ -0,0 +1,145 @@
1
+ ---
2
+ name: epmw
3
+ description: EPM Windows commands for endpoint privilege management. Use when working with Windows computers, policies, admin access requests, or audit logs.
4
+ ---
5
+
6
+ # EPM Windows Commands (`bt epmw`)
7
+
8
+ ## IMPORTANT: Destructive Operations
9
+
10
+ **ALWAYS confirm with the user before:**
11
+ - `bt epmw computers archive` - Archives computer from management
12
+ - `bt epmw groups delete` - Deletes computer group
13
+ - `bt epmw policies delete` - Deletes policy
14
+ - `bt epmw quick stale --delete` - Deletes stale computers
15
+
16
+ List affected resources first, then ask for explicit confirmation.
17
+
18
+ ## Quick Commands
19
+
20
+ ```bash
21
+ # Find stale computers (not checked in recently)
22
+ bt epmw quick stale # 24+ hours
23
+ bt epmw quick stale --hours 48 # 48+ hours
24
+ bt epmw quick stale -h 12 -g "Workstations"
25
+
26
+ # Delete stale computers
27
+ bt epmw quick stale --delete # With confirmation
28
+ bt epmw quick stale --delete --force # Skip confirmation
29
+
30
+ # Find disconnected computers
31
+ bt epmw quick disconnected
32
+ bt epmw quick disconnected -g "Servers"
33
+
34
+ # Status summary by group
35
+ bt epmw quick status
36
+ bt epmw quick status -g "Datacenter"
37
+ ```
38
+
39
+ ## Computers
40
+
41
+ ```bash
42
+ bt epmw computers list
43
+ bt epmw computers list -o json
44
+ bt epmw computers get <computer_id>
45
+ bt epmw computers delete <computer_id>
46
+ bt epmw computers archive <computer_id>
47
+ bt epmw computers unarchive <computer_id>
48
+ ```
49
+
50
+ ## Groups
51
+
52
+ ```bash
53
+ bt epmw groups list
54
+ bt epmw groups get <group_id>
55
+ bt epmw groups create --name "NewGroup" --description "Description"
56
+ bt epmw groups update <group_id> --name "UpdatedName"
57
+ bt epmw groups delete <group_id>
58
+ bt epmw groups assign-policy <group_id> --policy <policy_id>
59
+ bt epmw groups assign-computers <group_id> --computers <id1>,<id2>
60
+ ```
61
+
62
+ ## Policies
63
+
64
+ ```bash
65
+ bt epmw policies list
66
+ bt epmw policies get <policy_id>
67
+ bt epmw policies groups <policy_id> # Show assigned groups
68
+
69
+ # Download policy XML (for template)
70
+ bt epmw policies download <policy_id> > template.xml
71
+
72
+ # Create policy from XML
73
+ bt epmw policies create -n "My Policy" -f template.xml
74
+
75
+ # Policy revisions
76
+ bt epmw policies revisions list <policy_id>
77
+ bt epmw policies revisions get <policy_id> <revision_id>
78
+ bt epmw policies revisions upload <policy_id> -f policy.xml
79
+ ```
80
+
81
+ ## Admin Access Requests
82
+
83
+ ```bash
84
+ bt epmw requests list
85
+ bt epmw requests get <request_id>
86
+ bt epmw requests create --computer <id> --duration 30 --reason "Maintenance"
87
+ bt epmw requests approve <request_id>
88
+ bt epmw requests deny <request_id> --reason "Not authorized"
89
+ ```
90
+
91
+ ## Users & Roles
92
+
93
+ ```bash
94
+ bt epmw users list
95
+ bt epmw users get <user_id>
96
+ bt epmw users create --username "newuser" --email "user@example.com"
97
+ bt epmw users enable <user_id>
98
+ bt epmw users disable <user_id>
99
+ bt epmw users assign-roles <user_id> --roles <role1>,<role2>
100
+
101
+ bt epmw roles list
102
+ bt epmw roles get <role_id>
103
+ ```
104
+
105
+ ## Audits
106
+
107
+ ```bash
108
+ # Activity audits
109
+ bt epmw audits activity list
110
+ bt epmw audits activity get <audit_id>
111
+
112
+ # Authorization requests
113
+ bt epmw audits authorization list
114
+ bt epmw audits authorization get <audit_id>
115
+
116
+ # Request audits
117
+ bt epmw audits requests list
118
+ bt epmw audits requests get <audit_id>
119
+ ```
120
+
121
+ ## Key Groups
122
+
123
+ | ID | Name | Computers |
124
+ |----|------|-----------|
125
+ | 042267ec-... | Servers - Datacenter1 | CorpMem01, CorpMem02 |
126
+ | 1c8f6310-... | Workstations - Datacenter1 | CorpWS01, CorpWS02 |
127
+ | 67ca23ad-... | Engineering | BenC-Skynet |
128
+
129
+ ## Key Computers
130
+
131
+ | Host | Domain | Group | Status |
132
+ |------|--------|-------|--------|
133
+ | CorpMem01 | nexusdyn.corp | Servers | Connected |
134
+ | CorpMem02 | nexusdyn.corp | Servers | Connected |
135
+ | CorpWS01 | nexusdyn.corp | Workstations | Connected |
136
+ | CorpWS02 | nexusdyn.corp | Workstations | Connected |
137
+
138
+ ## API Notes
139
+
140
+ - Base path: `/management-api/v3`
141
+ - Token endpoint: `/oauth/token`
142
+ - Pagination: `pageNumber`/`pageSize`
143
+ - Response: `{"data": [...], "totalCount": N}`
144
+ - All IDs are UUIDs
145
+ - Delete returns 405 - use archive instead
@@ -0,0 +1,149 @@
1
+ ---
2
+ name: pra
3
+ description: Privileged Remote Access commands for jump items, vault accounts, and remote sessions. Use when working with PRA shell jumps, RDP, protocol tunnels, or SSH CA authentication.
4
+ ---
5
+
6
+ # PRA Commands (`bt pra`)
7
+
8
+ ## IMPORTANT: Destructive Operations
9
+
10
+ **ALWAYS confirm with the user before:**
11
+ - `bt pra jump-items shell delete` - Deletes shell jump item
12
+ - `bt pra jump-items rdp delete` - Deletes RDP jump item
13
+ - `bt pra jump-items tunnel delete` - Deletes protocol tunnel
14
+ - `bt pra jump-groups delete` - Deletes jump group
15
+ - `bt pra vault accounts delete` - Deletes vault account
16
+
17
+ List affected resources first, then ask for explicit confirmation.
18
+
19
+ ## Quick Commands
20
+
21
+ ```bash
22
+ # Vault credential checkout
23
+ bt pra quick vault # Interactive - shows accounts, prompts
24
+ bt pra quick vault -n "server-admin"
25
+ bt pra quick vault -n postgres --raw
26
+
27
+ # Search jump items and vault
28
+ bt pra quick search axion
29
+ bt pra quick search admin -o json
30
+ ```
31
+
32
+ ## Jump Items
33
+
34
+ ### Shell Jump (SSH/Telnet)
35
+
36
+ ```bash
37
+ bt pra jump-items shell list
38
+ bt pra jump-items shell get 55
39
+ bt pra jump-items shell create \
40
+ --name "web-server-01" \
41
+ --hostname "10.0.1.50" \
42
+ --jumpoint 3 \
43
+ --jump-group 24 \
44
+ --protocol ssh \
45
+ --port 22 \
46
+ --username "ec2-admin"
47
+ bt pra jump-items shell delete 55
48
+ ```
49
+
50
+ ### RDP Jump
51
+
52
+ ```bash
53
+ bt pra jump-items rdp list
54
+ bt pra jump-items rdp get 1
55
+ bt pra jump-items rdp create \
56
+ --name "win-server-01" \
57
+ --hostname "10.0.2.10" \
58
+ --jumpoint 3 \
59
+ --jump-group 31 \
60
+ --port 3389
61
+ ```
62
+
63
+ ### Protocol Tunnels (TCP/MSSQL/K8s)
64
+
65
+ ```bash
66
+ bt pra jump-items tunnel list
67
+ bt pra jump-items tunnel create \
68
+ --name "production-k8s" \
69
+ --hostname "k8s-api.example.com" \
70
+ --jumpoint 3 \
71
+ --jump-group 24 \
72
+ --type k8s \
73
+ --url "https://k8s-api.example.com:6443" \
74
+ --ca-cert "$(cat /path/to/ca.crt)"
75
+ ```
76
+
77
+ ## Jump Groups
78
+
79
+ ```bash
80
+ bt pra jump-groups list
81
+ bt pra jump-groups get 24
82
+ bt pra jump-groups create \
83
+ --name "Customer-05 (Bing7)" \
84
+ --code-name bing7 \
85
+ --comments "Demo customer"
86
+ bt pra jump-groups delete 30
87
+ ```
88
+
89
+ ## Vault Accounts
90
+
91
+ ```bash
92
+ bt pra vault accounts list
93
+ bt pra vault accounts get 6
94
+ bt pra vault accounts checkout 6
95
+ bt pra vault accounts checkin 6
96
+ bt pra vault accounts rotate 6
97
+
98
+ # SSH CA - get public key for provisioning
99
+ bt pra vault accounts get-public-key 31
100
+ ```
101
+
102
+ ## SSH CA Authentication
103
+
104
+ PRA supports SSH CA for ephemeral access - no static keys on hosts.
105
+
106
+ ```bash
107
+ # Get CA public key (ready for authorized_keys)
108
+ bt pra vault accounts get-public-key 31
109
+ # Output: cert-authority ssh-rsa AAAAB3NzaC1yc2E...
110
+
111
+ # Provision EC2 with SSH CA
112
+ PRA_CA_KEY=$(bt pra vault accounts get-public-key 31)
113
+ # Embed in user-data script for EC2
114
+ ```
115
+
116
+ **SSH CA Vault Accounts:**
117
+ | ID | Name | Username |
118
+ |----|------|----------|
119
+ | 3 | Ephemeral Admin SSH CA | admin-ephemeral |
120
+ | 31 | ec2-admin | ec2-admin |
121
+
122
+ ## CSV Import/Export
123
+
124
+ ```bash
125
+ bt pra export jump-items --file jump-items-template.csv
126
+ bt pra export vault-accounts --file vault-accounts-template.csv
127
+ bt pra import jump-items --file jump-items.csv --dry-run
128
+ bt pra import jump-items --file jump-items.csv
129
+ ```
130
+
131
+ ## Key IDs
132
+
133
+ | Resource | ID |
134
+ |----------|-----|
135
+ | Jumpoint: Data Center 01 | 2 |
136
+ | Jumpoint: AWS Account | 3 |
137
+ | Jump Group: Datacenter 01 (West) | 1 |
138
+ | Jump Group: Customer-01 (Axion) | 24 |
139
+ | Jump Group: Customer-02 (Meridian) | 25 |
140
+ | Jump Group: Cloud Containers | 26 |
141
+ | Vault: ec2-admin (SSH CA) | 31 |
142
+
143
+ ## API Notes
144
+
145
+ - Base path: `/api/config/v1`
146
+ - Pagination: `per_page`/`current_page` (1-indexed)
147
+ - Response: Array directly (pagination in headers)
148
+ - Jump item types have separate endpoints
149
+ - K8s tunnels require Linux jumpoint