%
if Request.ServerVariables("REQUEST_METHOD") = "POST" Then
Set CM = Server.CreateObject("Persits.CryptoManager")
Set Context = CM.OpenContext("mycontainer", True)
Set Hash = Context.CreateHash
Hash.AddText Request.Form("T1")
'generate random salt
Randomize
dim salt
salt = ""
for i = 1 to 10
'generate a character between A-Z
salt = salt & chr(int(Rnd * 26) + 65)
next
Hash.AddText salt
Response.Write salt & "
"
Response.Write Hash.Value.Hex
set CM = Nothing
set Context = Nothing
set Hash = Nothing
end if
%>
<%'My ASP program that formats dates
response.write "
" select case counter case 0 whichformat="vbgeneraldate" case 1 whichformat="vblongdate" case 2 whichformat="vbshortdate" case 3 whichformat="vblongtime" case 4 whichformat="vbshorttime" end select response.write "FormatDate(now()," & whichformat & ")=" response.write Formatdatetime(currentdate,counter) & "