3,825 reputation
1625
bio website
location Wellington, New Zealand
age
visits member for 2 years, 7 months
seen 30 secs ago

I am an undergraduate computer science and mathematics student in New Zealand. My fields of interest are computer graphics, in particular the physics of light transport, and to some extent cryptography, as well as programming and software development in general.


Jul
1
comment Exactly two of the four roots must be greater than N/2
@habillqabill Suppose $n$ is odd. Let $r$ be any integer between $1$ and $n$. Now suppose $r$ is less than $n/2$, then we are done. If $r$ is in fact greater than $n/2$, then $n - r < n/2$ and we are done. Basically, no matter $r$, either $r$ or $n - r$ will be less than $n/2$ (since both will fall on opposite sides of $n/2$). It's a symmetry argument.
Jul
1
revised Exactly two of the four roots must be greater than N/2
deleted 3 characters in body
Jul
1
answered Exactly two of the four roots must be greater than N/2
Jun
26
comment RSA example-calculation: Public Key = Private Key (e = d)
Note that $e$ cannot be its own inverse unless $e > \sqrt{\varphi(n)}$ (or $\lambda(n)$), or $e = 1$ of course, so in real usage with a normal public exponent $e$ this cannot happen.
Jun
22
comment Modulo settings for successful encryption?
You can emulate mod on a calculator like so: to compute a mod b, compute a/b, round it down, multiply b by the result and subtract a from it. E.g. for 77 mod 8, 77 / 8 = 9.62, so we have 77 mod 8 = 77 - 8 * 9 = 5. Or you can just multiply the fractional part by b, but you tend to run into precision issues quicker doing it that way.
Jun
14
comment Strategy for random CTR initial counter values
@RichieFrame "No message is more than $2^{32}−2$ blocks long"
Jun
11
comment Given $n$ bits, how many “truly random” sequences/numbers can be constructed?
@paul The basic idea of these test suites is to first assume you have access to a uniform bit generator (or a suitably large sample generated by said generator), run statistical tests on it, see how much the results deviate from the expected results, and then conclude after you have reached a statistically significant outcome. They don't measure the "randomness" of the data sample, they simply give confidence towards the hypothesis that "this generator produces uniformly distributed bits". Is this what you mean?
Jun
1
comment How Does Progressive Hashing Work?
It would be difficult to do otherwise, conceptually..
May
31
comment Correct way to read a given permutation cipher?
The first permutation just shifts each letter to the right cyclically. Look at the permutation: (1, 2, 3) => (3, 1, 2). So (1=V, 2=E, 3=N) is mapped to (3=N, 1=V, 2=E), that is, NVE.
May
31
answered RSA: Fermat's Little Theorem and the multiplicative inverse relationship between mod n and mod phi(n)
May
31
revised RSA: Fermat's Little Theorem and the multiplicative inverse relationship between mod n and mod phi(n)
cleaned latex a bit
May
30
comment Security of the iterated Hill Cipher
Note: the first two papers are behind a paywall.
May
27
comment Want to use ECC but am clueless
This is off-topic as it as about security software recommendation rather than actual cryptography. But I think you should really rethink your problem - generally end users should not concern themselves with which algorithms are being used to secure their data, just that it is, so a general purpose tool will probably serve you better (and it may or may not use elliptic curve technology), otherwise you are probably only going to find hobby, proof-of-concept tools that are probably flawed and insecure...
May
21
awarded  Enlightened
May
21
awarded  Nice Answer
May
20
comment Common password derivation function for different encryption methods
Don't both bcrypt and PBKDF2 let you choose an arbitrary output length? In that case what's wrong with simply choosing the key length of the block cipher to use next?
May
15
comment RSA private exponent primality
Specifically, $d$ is going to be an integer such that $ed - 1 = k\cdot \mathrm{lcm}(p - 1, q - 1)$ for some integer $k$, that is, $d = \frac{k \cdot \mathrm{lcm}(p - 1, q - 1) + 1}{e}$, so, really, its prime factorization could be anything, except it will always be coprime to $\mathrm{lcm}(p - 1, q - 1)$, that's about all you can say.
May
15
comment modulo operations in crypto algorithms
@user220201 This is when, e.g. using $e = 3$, we have $m < n^{1/3}$, in which case $c$ is literally $m^3$ and you can just take the cube root in the integers and decrypt the ciphertext using only public information. If $m > n^{1/3}$, then we only know that $c + kn$ is a perfect cube for some integer $k$, but this $k$ becomes very, very large on average as $m$ increases (with a very complicated distribution), making it impossible to brute force it without knowing the factors of $n$ (or so we believe).
May
14
comment RSA private exponent primality
The public exponent doesn't have to be a prime.
May
12
comment Generating unsigned, bounded random value using signed bounded random values
"All generated random values must have a normal distribution" is a non-issue, once you have a uniform distribution you can convert it to a normal distribution efficiently via inverse-transform sampling or specialized methods like Box-Muller. Focus on getting a uniform distribution (rejection sampling will probably be fast enough, except perhaps for pathological values of $x$).