121 reputation
6
bio website pvv.org/~rolfn
location Oslo, Norway
age 38
visits member for 2 years, 9 months
seen May 7 at 19:04

Computer professional working with architecture, requirements and project management.

Expert in java, SQL, xml and various internet protocols. Fluent in C and several unix-variants. Know some perl, python, common lisp, opengl, prolog, C++.

I am rolfn on keybase.io, and the proof is:

-----BEGIN PGP MESSAGE-----

owGbwMvMwMF4pylN96Bwigrj6QNJSQwhmtXTQjIyixWAKFGhODM9LzVFobgksSQ1
NzWvRCGtKD9XISg/J00hKDEvJbVIwW9icTEvl6dCYq5CRklJQbGVvn52amVSYnGq
Xma+fhFQZZ5Cfp4CVIyXyzEvBawQqA5oanJ2akVyRmJeeqpecn6ufmlxalGxvpGB
gYEFWKtuEcQSoAHBIMUKrlDVvFy+lQoF6QW6QHMV0jKBIkUFRZlA92UWWymYuhha
KBiZmjsrWLqZmCqYGxpYKLi4OZopOLqYGiq4OFsYKZiZGbkoOBsaGiuYmRiZ8HKF
ZOamAp2TW2Cl4AuyLLVAwchSwdDcysjYythEwdk1OETByMAQqLKTUYaFgZGDgY2V
CRhUsxi4OAVgATgphv2/z//aHN8qXwvlJZOeveJ1KGqqqH6qLjJHNkvfUZA5/aa7
26swXunAu0bTJM6LVcrMfTrxwFx+nuW6HacDVSd7FS39G8OVvLL72QeV7lJGa4U/
2yaqSex/NKftpNe7M51ybSkHputP1Z7vxsGn+ryALzft0uJDaYHvPSQcL5qKxjRo
HlZI8dEMafHVOmRT+Kap9kXVOwH3yYyK5wtt7rH9jVBQ8Uz/JPhcuPDpo0SLqysU
+/8HmzQ+7bvtVi3kIsg4a+rpmRUSAYvEwpznvHDT5/mR7fBlogyzu+W025rsP/4/
mLfrYA3nvp1ah5m+iW7LW9pgZDeD0e7vxG/KGUa+MuL62/c/Y/SZdC2iFAA=
=ac7u
-----END PGP MESSAGE-----

Apr
8
comment Encrypting many small messages (log-lines)
A small update on this: I took a look in Practical Cryptography (Ferguson/Schneier) which actually recommends using an encrypted message counter as IV, because you typically need a message counter anyway to prevent message replay or message deletion, and for a counter 48 or 64 bits would be sufficient.
Mar
18
awarded  Teacher
Mar
14
awarded  Scholar
Mar
14
accepted Encrypting many small messages (log-lines)
Mar
14
awarded  Supporter
Mar
14
awarded  Editor
Mar
14
revised Encrypting many small messages (log-lines)
added 1002 characters in body
Mar
14
comment Encrypting many small messages (log-lines)
This was javax.crypto with default settings, I was not aware of the possibility (or consequences) of changing the key parameters. I will update with more info.
Mar
13
answered Encrypting many small messages (log-lines)
Mar
12
comment Encrypting many small messages (log-lines)
I don't think message replay is a problem. This is a logging setup, and each log-message will probably have both a timestamp and a unique id. False messages might be a problem (sender A sending messages pretending to be from B), but that would be much harder to solve.
Mar
12
comment Encrypting many small messages (log-lines)
I don't know if gzip reduces message-size, I'll benchmark that. However, it is common common advice to compress messages before encryption to make a known-plaintext attack harder. In cryptographic context, the point of integrity is usually to ensure who has sent the message, and to achieve that I would need to sign it with the senders private key. That would be unfeasible for logging, I'll look in to this further.
Mar
12
comment Encrypting many small messages (log-lines)
Thank you, I see there are some blank spots in my understanding of RSA, reading up on OAEP now...
Mar
12
comment Encrypting many small messages (log-lines)
The AES "session key" will be included in the log-message, encrypted with RSA. I believe this is the common mode of operation when using asymetric encryption: use RSA to encode a session key, include the encoded key in the message.
Mar
12
comment Encrypting many small messages (log-lines)
Hm, looking more at this, I guess I need an IV in the first example as well.
Mar
12
awarded  Student
Mar
12
comment Encrypting many small messages (log-lines)
Great input. I won't implement RSA or AES myself, I'll use javax.crypto. I will probably benchmark to find out if the re-use of keys is neccessary.
Mar
12
asked Encrypting many small messages (log-lines)
Jan
20
awarded  Autobiographer