Skip to content

feat(DIS-4350): add protective monitoring to dp-identity-api#254

Merged
tjoluotch merged 6 commits into
developfrom
feature/add-protective-monitoring
May 14, 2026
Merged

feat(DIS-4350): add protective monitoring to dp-identity-api#254
tjoluotch merged 6 commits into
developfrom
feature/add-protective-monitoring

Conversation

@tjoluotch
Copy link
Copy Markdown
Contributor

@tjoluotch tjoluotch commented May 13, 2026

What

Added protetctive monitioring given authentication data to the necessary handlers

How to review

All handlers that are sensitive have protective monitoring

Who can review

!me

@tjoluotch tjoluotch requested a review from a team as a code owner May 13, 2026 10:14
Copy link
Copy Markdown
Contributor

@lindenmckenzie lindenmckenzie left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Few minor bits.

Comment thread api/groups.go
Comment thread api/groups.go
Comment thread api/groups.go Outdated
var (
GroupsUsersList *[]models.ListGroupUsersType
)
authEntityData, ok := authorisation.AuthEntityDataFromContext(req.Context())
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Not a sensitive read endpoint so not required.

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

change made

Comment thread api/users.go
}

// ListUsersHandler lists the users in the user pool
func (api *API) ListUsersHandler(ctx context.Context, _ http.ResponseWriter, req *http.Request) (*models.SuccessResponse, *models.ErrorResponse) {
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Not a sensitive read endpoint so not required.

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

change made

Comment thread api/users.go
Comment thread api/users.go
Comment thread models/audit_event.go Outdated
@@ -0,0 +1,17 @@
package models

// Action represents the action that was performed on the policy
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It's not on a policy :)

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

change made

Comment thread models/audit_event.go Outdated
Comment on lines +6 to +17
// Outcome represents the outcome of the action
type Outcome string

const (
ActionCreate Action = "CREATE"
ActionRead Action = "READ"
ActionUpdate Action = "UPDATE"
ActionDelete Action = "DELETE"

OutcomeSuccess Outcome = "success"
OutcomeFailure Outcome = "failure"
)
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

We might want to consider moving these to the logging library - probably not one for now though.

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@tjoluotch tjoluotch merged commit cc3f007 into develop May 14, 2026
8 checks passed
@tjoluotch tjoluotch deleted the feature/add-protective-monitoring branch May 14, 2026 08:39
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants