Class WebExchangeSessionHandler
java.lang.Object
es.kukenan.smartfi.microservice.security.gateway.handler.WebExchangeSessionHandler
Handler request decrypt request body.
-
Field Summary
FieldsModifier and TypeFieldDescriptionprivate EncryptDecryptDataEncryptDecryptData operations.private SessionCacheOperationCacheOperation cache operations.private SessionCacheUtilitiesSession cache operations. -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionbyte[]decryptData(String requestBody, es.kukenan.smartfi.microservice.security.gateway.cache.model.SessionCache sessionCache) Decrypt data request for security gateway endpoints.es.kukenan.smartfi.microservice.security.gateway.cache.model.SessionCachegetWebExchangeSession(org.springframework.web.server.ServerWebExchange exchange) Operation cache for request.voidhandlerApiRequestExchangeSessionHandle(org.springframework.web.server.ServerWebExchange exchange) Get uuid header in request and decrypt body request and add authorization header.
-
Field Details
-
sessionCacheOperation
CacheOperation cache operations. -
encryptDecryptData
EncryptDecryptData operations. -
sessionCacheUtilities
Session cache operations.
-
-
Constructor Details
-
WebExchangeSessionHandler
public WebExchangeSessionHandler()
-
-
Method Details
-
handlerApiRequestExchangeSessionHandle
public void handlerApiRequestExchangeSessionHandle(org.springframework.web.server.ServerWebExchange exchange) Get uuid header in request and decrypt body request and add authorization header.- Parameters:
exchange- Server web exchange for share attributes.
-
decryptData
public byte[] decryptData(String requestBody, es.kukenan.smartfi.microservice.security.gateway.cache.model.SessionCache sessionCache) throws IOException Decrypt data request for security gateway endpoints.- Parameters:
requestBody- Body request with encrypted data.sessionCache- Session cache for get symmetric key and seed for decrupt request body.- Returns:
- byte[] decrypted request array of bytes.
- Throws:
IOException- Object mapper for get json body request.
-
getWebExchangeSession
public es.kukenan.smartfi.microservice.security.gateway.cache.model.SessionCache getWebExchangeSession(org.springframework.web.server.ServerWebExchange exchange) Operation cache for request.- Parameters:
exchange- server web exchange.- Returns:
- session cache operation.
-