0

My project is about sending a random number from client side to server side. Since my random number should be approved by FIPS 196, I wonder if there is a way that I can generate this random number both in VBscript and Javascript. Thank you

A23149577
  • 2,045
  • 2
  • 40
  • 74
  • VBScript? I'm curious, what environment are you using where you need to use VBScript in 2013? – T.J. Crowder Feb 12 '13 at 08:23
  • Actually I am trying to develop a public key enable web application which should be implemented with both javascript and vbscript at the client side, I need to generate a random number and concatenate it with challenge which is sent from server as it mentioned in FIPS-196. – A23149577 Feb 12 '13 at 08:30
  • @ Amir: My question remains: Why do you need both JavaScript *and* VBScript? There is no web browser that supports VBScript that doesn't also support JavaScript. Why the double effort? – T.J. Crowder Feb 12 '13 at 08:33
  • You are totally right, in practice that's the double effort. But I am trying to develop PKE web application samples which should be implemented in different platforms for different users. I mean what if one of my customers need a sample in VBscript? – A23149577 Feb 12 '13 at 09:59
  • @ Amir: Okay, fair enough. Mind you, I think I'd provide them a sample in JavaScript and an explanation of why they don't need VBScript, but... :-) – T.J. Crowder Feb 12 '13 at 10:08
  • @T.J.Crowder: Dude, I would do the same if I were project manager ;-) – A23149577 Feb 12 '13 at 10:29

1 Answers1

0

I found a solution, it can be done with CAPICOM object with GetRandom method. It seems that this solution is the most secure way for generating random number in VBscript.

A23149577
  • 2,045
  • 2
  • 40
  • 74