Is it secure to concatenate numbers from an RNG with numbers from a PRNG? I was thinking to throw a dice and use four outcomes to use as real random numbers, one outcome to change to the next permutation, and one outcome to add a pseudo-random number:
I generate a pseudo-random shuffled array from all permutations of the eyes:
shuffle([[1, 2, 3, 4, 5, 6], [1, 2, 3, 4, 6, 5], ...])
I choose the first permutation of the array.
Then I throw a dice. If the position of the eyes in the permutation is 0 to 3, then I add the values
11 to the sequence according to the position. If the position of the value in the permutation is 4, I get 1 byte random from the PRNG (with node.js
crypto.randomBytes function) and add it to the sequence. If the position of the value in the permutation is 5, then I get 2 bytes random from the PRNG and add it to the sequence. After each dice throw i change the permutation to a randomly chosen permutation. Repeating this, I would get about 25% RNG and 75% PRNG values. But the position of mixing would be random and depending on the eyes I dice.
Would this make the generated number more secure? Or is there a better way to mix these values? How does the percentage of the random number influence the quality of the total number?