Created
August 2, 2019 10:15
-
-
Save cyborch/9c47d71caa462be772baa28ee59be647 to your computer and use it in GitHub Desktop.
Verifier service for cryptographic accumulator
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
fun main() { | |
val app = Javalin.create().start(7000) | |
app.post("/verify") { ctx -> | |
val body = ctx.bodyAsClass(VerifyBody::class.java) | |
ctx.json(RSAAccumulator.verifyMembership(BigInteger(body.commitment), body.proof)) | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment