-
Notifications
You must be signed in to change notification settings - Fork 5
Fix/evault access guard permission issue #646
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
Conversation
|
Caution Review failedThe pull request is closed. 📝 WalkthroughWalkthroughIntroduces comprehensive infrastructure and authentication overhaul: adds Docker Compose configurations for core and social services with updated Node.js base images (18→20), adds Bearer token authentication to eVault-core GraphQL operations, removes provisioning-related entities and services, and expands Docker management scripts in package.json. Changes
Sequence Diagram(s)sequenceDiagram
participant Client
participant GraphQL as GraphQL Server
participant Guard as VaultAccessGuard
participant Resolver as Resolver Logic
participant DB as Database
Client->>GraphQL: GraphQL Query/Mutation
Note over GraphQL: Inspect operation type
alt Store Operation (storeMetaEnvelope)
GraphQL->>Guard: validateAuthentication(context, true)
Guard->>Guard: Check X-ENAME header
alt X-ENAME present & non-empty
Guard->>Guard: Extract eName
rect rgb(200, 220, 200)
Note over Guard: Optional: parse Bearer token
end
Guard->>GraphQL: ✓ Auth passed
else X-ENAME missing/empty
Guard->>GraphQL: ✗ Throw error
GraphQL->>Client: 401 Unauthorized
end
else Read/Update Operation
GraphQL->>Guard: validateAuthentication(context, false)
Guard->>Guard: Check Authorization header
alt Valid Bearer token
Guard->>Guard: Validate JWT
rect rgb(200, 220, 200)
Note over Guard: Extract tokenPayload
end
Guard->>GraphQL: ✓ Auth passed
GraphQL->>Resolver: Execute resolver
Resolver->>DB: Perform operation
DB->>Resolver: Return data
Resolver->>GraphQL: Return result
GraphQL->>Client: 200 Result
else No token or invalid token
Guard->>GraphQL: ✗ Throw error
GraphQL->>Client: 401 Unauthorized
end
end
Estimated code review effort🎯 4 (Complex) | ⏱️ ~60 minutes Possibly related PRs
Suggested labels
Suggested reviewers
Poem
✨ Finishing touches
📜 Recent review detailsConfiguration used: defaults Review profile: CHILL Plan: Pro 📒 Files selected for processing (31)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
Description of change
Issue Number
closes #645
Type of change
How the change has been tested
Change checklist
Summary by CodeRabbit
New Features
Bug Fixes
Documentation
Chores
✏️ Tip: You can customize this high-level summary in your review settings.