blob: 3d9055c6386c68c412b1a4ca349ef48dbff825df [file] [log] [blame]
<?xml version = "1.0" encoding="utf-8" ?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN"
"DTD/xhtml1-strict.dtd">
<html xmlns = "http://www.w3.org/1999/xhtml">
<head>
<title>NDN Request Example</title>
<script language="JavaScript" type="text/javascript" src="securityLib/jsbn.js"></script>
<script language="JavaScript" type="text/javascript" src="securityLib/jsbn2.js"></script>
<script language="JavaScript" type="text/javascript" src="securityLib/rsa.js"></script>
<script language="JavaScript" type="text/javascript" src="securityLib/rsa2.js"></script>
<script language="JavaScript" type="text/javascript" src="securityLib/sha1.js"></script>
<script language="JavaScript" type="text/javascript" src="securityLib/sha256.js"></script>
<script language="JavaScript" type="text/javascript" src="securityLib/sha512.js"></script>
<script language="JavaScript" type="text/javascript" src="securityLib/md5.js"></script>
<script language="JavaScript" type="text/javascript" src="securityLib/ripemd160.js"></script>
<script language="JavaScript" type="text/javascript" src="securityLib/base64.js"></script>
<script language="JavaScript" type="text/javascript" src="securityLib/rsapem-1.1.min.js"></script>
<script language="JavaScript" type="text/javascript" src="securityLib/rsasign-1.2.min.js"></script>
<script language="JavaScript" type="text/javascript" src="securityLib/asn1hex-1.1.min.js"></script>
<script language="JavaScript" type="text/javascript" src="securityLib/x509-1.1.min.js"></script>
<script type="text/javascript">
function hash(){
var input = document.getElementById('contentname').value;
var output = hex_sha256(input);
document.getElementById('result').innerHTML = output;
}
</script>
</head>
<body >
<form>
Please Enter a Text to sign:<br /><input id="contentname" type="text" name="CONTENTNAME" value="/PARC/abc" /> <br />
</form>
<button onclick="hash()">Hash</button>
<p id="result"></p>
</body>
</html>