feat: add input validation/sanitization and error handling/logging in real-time gateway endpoints#145
feat: add input validation/sanitization and error handling/logging in real-time gateway endpoints#145slopefields wants to merge 6 commits into
Conversation
…dpoint_sanitization
…point_sanitization
| const MAX_BODY_KEYS = 50; | ||
| const MAX_STRING_VALUE_LENGTH = 10000; | ||
| const APP_HEADER_PREFIX = 'x-'; | ||
| const ALLOWED_GAMIFICATION_EVENT_TYPES = new Set([ |
There was a problem hiding this comment.
This is useless, we don't need gamification types
| }; | ||
| }; | ||
|
|
||
| export const validateEmitGamificationBody: BodyValidator = (body: Record<string, unknown>): string | null => { |
| res.json({ success: true }); | ||
| }); | ||
| // Emit based on type | ||
| switch (type) { |
There was a problem hiding this comment.
Factor this out, this is unnecessary
|
@Team-Deepiri/support-team someone test this @slopefields reference your other PRs from other repos into here |
|
@slopefields take out all gamification stuff |
|
@Todd838 This is the main PR related to the one you've been assigned to in the api-gateway repo. Keep this in mind when you're testing that; since they're connected like this, it's generally better if one person handles the lot for consistency, but if you need backup please let me know! |
|
@Todd838 Let's get this wrapped up this week please, if you're having issues just reach out. If I don't hear back from you in a few days I'll be reassigning this and taking you out of rotation until you reach out to me, communication is key! |
|
@8techy Take over this |
|
@Team-Deepiri/support-team |
Todd838
left a comment
There was a problem hiding this comment.
in server.ts, it currently currently imports @deepiri/shared-utils instead of @team-deepiri/shared-utils
|
@austinm2h35-sketch @SeanSan06 assign someone to this instead |
|
@Todd838 We need to talk about your performance, it looks like you just gave a half assed review. |
|
@Yoloholoknow You have the other half of this assigned, makes the most sense for you to cover the rest of it. It includes this as well as 40 in api-gateway, 35 in external-bridge-service, and 31 in auth-service (the one you're handling right now). Thank you! |
Description
Adds input (body, header, query) validation/sanitization and error handling/logging across real-time gateway endpoints
Changes
Related
Related PRs (not dependent):
deepiri-external-bridge-service: Team-Deepiri/deepiri-external-bridge-service#35
deepiri-auth-service: Team-Deepiri/deepiri-auth-service#31
deepiri-api-gateway: Team-Deepiri/deepiri-api-gateway#40
Testing
Workflow Checklist
Review Requests
@Team-Deepiri/support-team