-
Notifications
You must be signed in to change notification settings - Fork 29
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Update User Audit Scripts for Pagination #240
Conversation
User Audit/useraudit.py
Outdated
base_url = "https://api.kennasecurity.com" | ||
users_url= base_url + "/users" | ||
# increase per_page to get more data per request | ||
per_page = 10 |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
can this be configurable like user can adjust this number?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
these scripts are sent to the client so either CX or client can customize the scripts. I have added a small README snippet about per_page
but I do not see the need to make it a CLI option. I do not like the way CLI is being used in user audit script but not planning to change it
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Performed a test run for my environment and all users were returned with appropriate data
@@ -33,5 +33,8 @@ You can set an environment variable in Windows using the setx command in the com | |||
In macOS or Linux, you can set an environment variable in the terminal using the export command: | |||
*export API_KEY=your-api-key* | |||
|
|||
### 4. Pagination Size |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Nitpick: this should go after # 3. Also, it should keep the same format: 4:
.
VM-5208
The script will work for both paginated and unpaginated API.
paginated response for useraudit.py
for audit script