You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
During presentation exchange I noticed that the same validations or decoding of jwt token in underlying methods happens multiple times.
Problem in PresentationExchange.validatePresentationsAgainstDefinition(). Here you have filterOutCorrectPresentation() method that invoke pex.evaluatePresentation() and do filtering to get only correct presentation definitions. After that in validatePresentationsAgainstDefinition() you have the same pex.evaluatePresentation() to do validation. But actually you made this validation previously, so no point to do this one more time. And at the end of method you have PresentationExchange.validatePresentationAgainstDefinition() where you one more time create PEX and call evaluatePresentation() for validation.
So maybe you can revise this method and optimize it so that you don't do the same checks multiple times. Because it slows down the presentation exchange process.
The text was updated successfully, but these errors were encountered:
nklomp
transferred this issue from Sphereon-Opensource/SIOP-OID4VP
Oct 2, 2024
During presentation exchange I noticed that the same validations or decoding of jwt token in underlying methods happens multiple times.
Problem in PresentationExchange.validatePresentationsAgainstDefinition(). Here you have filterOutCorrectPresentation() method that invoke pex.evaluatePresentation() and do filtering to get only correct presentation definitions. After that in validatePresentationsAgainstDefinition() you have the same pex.evaluatePresentation() to do validation. But actually you made this validation previously, so no point to do this one more time. And at the end of method you have PresentationExchange.validatePresentationAgainstDefinition() where you one more time create PEX and call evaluatePresentation() for validation.
So maybe you can revise this method and optimize it so that you don't do the same checks multiple times. Because it slows down the presentation exchange process.
The text was updated successfully, but these errors were encountered: