deserialization issue affecting APIGatewayCustomAuthorizerContext
- Lingua principale
- C#
- Stelle
- 1.7k
- Fork
- 503
- Merge medio
- 1g 13h
- PR unite (30g)
- 19
Descrizione
### Describe the bug
Not able to consume values returned by a Lambda Authorizer; they are not there even if they are present in the input JSON
### Expected Behavior
Dictionary properly set with keys and values
### Current Behavior
No values
### Reproduction Steps
Websocket API with an authorizer; try to access any authorizer context property (like principalId)
Use the new "Amazon.Lambda.Serialization.SystemTextJson.DefaultLambdaJsonSerializer" (which is default)
### Possible Solution
As a workaround, the old "Amazon.Lambda.Serialization.Json.JsonSerializer" using the Newtonsoft library seems to work just fine.
### Additional Information/Context
using Amazon.Lambda.Serialization.SystemTextJson.DefaultLambdaJsonSerializer
"Authorizer": {
"principalId": {
"ValueKind": 3
},
"integrationLatency": {
"ValueKind": 4
},
"authn": {
"ValueKind": 3
}
}
using the legacy Amazon.Lambda.Serialization.Json.JsonSerializer
"Authorizer": {
"principalId": "***********************",
"integrationLatency": 9516,
"authn": "None"
},
### AWS .NET SDK and/or Package version used
Amazon.Lambda.Serialization.SystemTextJson v2.3.0
### Targeted .NET Platform
.net core 3.1
### Operating System and version
any
Guida per i contributori
Apri la guida per i contributori
Direzione di ricerca
Inizia riproducendo il caso dell’authorizer di WebSocket API con Amazon.Lambda.Serialization.SystemTextJson.DefaultLambdaJsonSerializer v2.3.0, quindi confronta il relativo output APIGatewayCustomAuthorizerContext con quello di legacy JsonSerializer. Traccia la deserializzazione del dizionario Authorizer e conferma che principalId, integrationLatency, authn e gli altri valori restituiti vengano preservati; nel report non viene nominato alcun file sorgente né alcun test.
Scritto dal modello di indicizzazione a partire dal testo della issue.
Valutazione
- Stack tecnologico
- aws, csharp
- Ambito
- api, backend, cloud
- Tipo di issue
- Bug
- Difficoltà
- 4/5
- Tempo stimato
- 3-5 giorni
- Stato di attività
- Ferma
- Chiarezza
- Da chiarire
- Idoneità per principianti
- 30/100