diff options
Diffstat (limited to 'tests/dpop-proof-replay.scm')
-rw-r--r-- | tests/dpop-proof-replay.scm | 23 |
1 files changed, 12 insertions, 11 deletions
diff --git a/tests/dpop-proof-replay.scm b/tests/dpop-proof-replay.scm index 19e6a30..5720d93 100644 --- a/tests/dpop-proof-replay.scm +++ b/tests/dpop-proof-replay.scm @@ -31,23 +31,24 @@ (define cnf (jkt jwk)) (define proof (parameterize ((p:current-date 0)) - (issue-dpop-proof - jwk - #:htm 'GET - #:htu (string->uri "https://example.com/res#frag")))) - (define (decode) + (issue <dpop-proof> + jwk + #:jwk (public-key jwk) + #:htm 'GET + #:htu (string->uri "https://example.com/res#frag")))) + (define (do-decode) (parameterize ((p:current-date 10)) - (dpop-proof-decode 'GET - (string->uri "https://example.com/res?query") - proof - cnf))) - (define decoded-once (decode)) + (decode <dpop-proof> proof + #:method 'GET + #:uri (string->uri "https://example.com/res?query") + #:cnf/check cnf))) + (define decoded-once (do-decode)) (with-exception-handler (lambda (error) (unless (jti-found? error) (raise-exception error))) (lambda () - (decode) + (do-decode) (exit 2)) #:unwind? #t #:unwind-for-type &jti-found))) |