mirror of
https://github.com/ashinn/chibi-scheme.git
synced 2025-07-03 19:26:36 +02:00
Updating snow package utils to use pkcs1 padding.
This commit is contained in:
parent
34e1a27cb1
commit
638ea1bf8a
2 changed files with 3 additions and 2 deletions
|
@ -11,7 +11,7 @@
|
|||
(else (call-with-output-string (lambda (out) (display x out))))))
|
||||
|
||||
(define (maybe-parse-hex x)
|
||||
(if (string? x) (string->number x 16) x))
|
||||
(if (string? x) (hex-string->bytevector x) x))
|
||||
|
||||
;; rsa key utils
|
||||
|
||||
|
@ -134,7 +134,7 @@
|
|||
(maybe-parse-hex digest)
|
||||
(maybe-parse-hex sig)))
|
||||
`(sign: rsa-signature-invalid: digest: ,digest sig: ,sig
|
||||
actual: ,(rsa-encrypt rsa-key digest)))
|
||||
actual: ,(rsa-verify rsa-key (maybe-parse-hex digest))))
|
||||
(else #f))))
|
||||
|
||||
(define (package-signature-ok? cfg pkg raw)
|
||||
|
|
|
@ -17,6 +17,7 @@
|
|||
(import (chibi)
|
||||
(srfi 1)
|
||||
(chibi snow interface)
|
||||
(chibi bytevector)
|
||||
(chibi config)
|
||||
(chibi crypto md5)
|
||||
(chibi crypto rsa)
|
||||
|
|
Loading…
Add table
Reference in a new issue