Reduce dependencies in make.network.randomIPv6
This commit is contained in:
parent
7f68b11902
commit
be4fef5d86
1 changed files with 7 additions and 3 deletions
|
@ -48,9 +48,13 @@ make.network = {
|
||||||
random.pick([random.number(255), make.number.any])
|
random.pick([random.number(255), make.number.any])
|
||||||
},
|
},
|
||||||
randomIPv6: function () {
|
randomIPv6: function () {
|
||||||
return '[' + make.strings.stringFromBlocks([':', function () {
|
let parts = []
|
||||||
return make.strings.digitsHex(random.range(1, 4))
|
|
||||||
}]) + ']'
|
for (let i=0; i<8; i++) {
|
||||||
|
parts.push(random.hex(4))
|
||||||
|
}
|
||||||
|
|
||||||
|
return parts.join(':')
|
||||||
},
|
},
|
||||||
goodHostnames: function () {
|
goodHostnames: function () {
|
||||||
return [
|
return [
|
||||||
|
|
Loading…
Reference in a new issue