fix(tests+security): custom script timeout tests, client-id metric, test fixes, ArangoDB hardening#580
Open
lakhansamani wants to merge 2 commits intomainfrom
Open
fix(tests+security): custom script timeout tests, client-id metric, test fixes, ArangoDB hardening#580lakhansamani wants to merge 2 commits intomainfrom
lakhansamani wants to merge 2 commits intomainfrom
Conversation
…c, fix test suite, harden ArangoDB queries - Add comprehensive tests for custom access token script timeout (#571): custom claims, reserved claim protection, infinite loop timeout, error handling, ID token claims - Add client-id mismatch security metric (skips dashboard/admin/app paths) - Convert ArangoDB pagination from fmt.Sprintf %d to bind variables (@offset, @limit) - Fix SSRF validation to skip in test environment for TestEndpoint - Fix TestJWKSEndpointCompliance: test both HMAC (empty keys) and RSA (valid keys) - Fix TestAddWebhookTest: use unique event name to avoid data isolation issues - Fix TestResendOTP, TestVerifyOTP, TestResetPassword, TestUpdateProfile: replace hardcoded phone numbers with unique values to prevent cross-test collisions - All tests pass with make test-sqlite (86 test cases)
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
New Tests
Security Improvements
authorizer_security_events_total{event="client_id_mismatch"}when an invalid client ID is provided, excluding/dashboardand/apppaths to avoid noise from internal UI requestsLIMIT %d, %dpatterns toLIMIT @offset, @limitwith bind variables for defense-in-depth consistency across 5 ArangoDB provider filesTest Suite Fixes (all 86 test cases now pass)
UserDeactivatedWebhookEventto avoid data isolation issues with other webhook testsFiles Changed
internal/integration_tests/custom_access_token_script_test.go— new test file (7+3 test cases)internal/http_handlers/client_check.go— add security metric on mismatchinternal/graphql/test_endpoint.go— skip SSRF in test envinternal/storage/db/arangodb/{user,email_template,verification_requests,webhook_log,audit_log}.go— bind variablesinternal/integration_tests/{add_webhook,oauth_standards_compliance,resend_otp,reset_password,update_profile,verify_otp}_test.go— test fixesTest plan
make test-sqlitepasses (86/86 test cases, 0 failures)make test-arangodbto verify bind variable changes