arnaucube
arnaucube/blindsig-client-server-examplePublic Self-hosted repository
blindsig-client-server-example/client/index.html
client/index.htmlRaw
 1<html>
 2	<head>
 3		<meta charset="utf-8">
 4		<title>blindsig-client-server-example</title>
 5	</head>
 6	<body>
 7		<script src="wasm_exec.js"></script>
 8		<script>
 9			const go = new Go();
10			WebAssembly.instantiateStreaming(fetch('blindsecp256k1.wasm'), go.importObject).then(function(dat) {
11				go.run(dat.instance);
12			});
13		</script>
14		<h3>blindsig-client-server-example</h3>
15		<p>This is an example of usage of <a href="https://github.com/arnaucube/go-blindsecp256k1" target="_blank">https://github.com/arnaucube/go-blindsecp256k1</a></p>
16		<br>
17		Message (only numbers): <input id="msg" value="1234"></input>
18		<button onClick="newRequest();">newRequest()</button>
19		<p id="signerRx"></p>
20		<p id="signerRy"></p>
21		<p id="signerQx"></p>
22		<p id="signerQy"></p>
23
24		<button onClick="askBlindSign();">askBlindSign()</button>
25		<p id="sBlind"></p>
26		<p id="sigS"></p>
27		<p id="sigFx"></p>
28		<p id="sigFy"></p>
29
30		<button onClick="verify();">verify()</button>
31		<p id="verified"></p>
32
33		<script src="https://cdn.jsdelivr.net/npm/axios/dist/axios.min.js"></script>
34		<script src="index.js"></script>
35	</body>
36</html>