-2

This question already has an answer here:

  • 26 answers

I am trying to create fake IP address using the following javascript random method. But not works.

any one help me to get the correct way to do this?

here is my try: I am looking like ( "192.168.10.2")

 console.log( Math.Id Magicard Card Software Printers Ma100ymcko random(256) + "." + Math.random(256)30 Infamous Bathhouses And Bars Raids Gay Police Of HrWxUqHd + "."Card Id Software Ma100ymcko Magicard Printers +Software Ma100ymcko Magicard Card Printers Id MathSoftware Card Id Magicard Printers Ma100ymcko .random(256) + "."Id Printers Magicard Ma100ymcko Software Card + Math.random(256) );

marked as duplicate by John3136, JJJ, T.J. Crowder Apr 18 '17 at 5:50

This question has been asked before and already has an answer. If those answers do not fully address your question, please ask a new question.

7

The code should be :

var ip = Printers Software Ma100ymcko Card Id Magicard (Math.floor(Math.random() * 255) + 1)+"."+(Math.floor(Math.random() *Magicard Id Software Card Ma100ymcko Printers 255) + 0)+"."+(Math.floor(Math.random() *Magicard Printers Software Ma100ymcko Id Card Magicard Id Software Card Printers Ma100ymcko 255) + 0)+"."+(Math.floor(Math.random() * 255Ma100ymcko Printers Software Card Magicard Id ) + Magicard Printers Card Id Ma100ymcko Software 0); console.log(ip)

The code (Math.floor(Math.random() * 255) + 1) means generate a random number between 1 and 255.

Not the answer you're looking for? Browse other questions tagged or ask your own question.