« first day (1004 days earlier)      last day (4174 days later) » 

03:14
@TerryChia : I searched your name there and this was the resuslt: TerryChia = A$$hole! — Andrew 5 hours ago
@TildalWave lol.
@RoryMcCune Melon!
@ScottPack I can't believe @AviD missed that. Must be getting old.
 
2 hours later…
05:39
heh.
@TerryChia oo, but that makes it look like you're so rich you have cash flowing out of your rectum!
06:31
@AviD Hmmmmmm
checks rectum nope...
 
3 hours later…
09:26
Comments, criticisms and pitchforks please. :) github.com/Ayrx/pyDropSecure
@terry - you don't need to check yourself... Just take a flight to the US. They have a lovely team called the TSA who well do that for you. For free.
did you know that there is a 2 girls 1 cup parody song, dong in a country music stylee
09:44
@RoryMcCune I'm not sure how to respond to that.
@TerryChia I think this is the proper response.
10:28
@RoryMcCune I did not know that
You guys may enjoy this
0
Q: Syntax of 'f*** off has he', 'b******* do they', and the like

Luke BradleyIs anybody aware of published analysis of this interesting construction, which seems to require what I will loosely term swear words to work? I believe I've only heard it in British English: A1 - Dave got a job at Roche. B1 - Fuck off did he! (=No he didn't; I don't believe you) A2 -...

morning gents
@Terry
mornin'
10:45
@RoryAlsop I didn't either till XBOX music misheard a search for "some girls wander"
@RoryMcCune hahaha - suuure
11:38
@TerryChia spec?
@CodesInChaos Hm? What spec?
you wrote some crypto, so I'm asking for the specification
@CodesInChaos Ohh. It's nothing fancy. I'm just encrypting file contents on the client side before uploading it to dropbox. AES-128-CBC with HMAC applied.
which mode? Where does the IV come from?
doesn't a random IV break the synchronization?
@CodesInChaos Basically this code snippet, code.activestate.com/recipes/… but with a 128 bit key instead of 192.
11:44
but since a file encrypts differently each time, how would the sync work?
@CodesInChaos I'm trying to make the whole thing as seamless as possible, so the file isn't encrypted when stored on the client-side. It's encrypted right before uploading it.
It obviously doesn't protect against bad things on the client-side.
I just re-encrypt the file when it's modified locally before uploading it.
but wouldn't randomized encryption break dropbox synchronization?
@CodesInChaos I'm actually handling the synchronization on my own. What the Dropbox API offers is a way to put/remove files on their servers as well as obtain a "delta" of changes to a Dropbox folder.
Which is based on metadata, not the actual file contents.
Your code contains one hard to exploit mistake: You're not using a constant time comparison to verify the MAC
@CodesInChaos Ahh damn. Timing attacks right?
11:55
yeah, but in your specific scenario it seems difficult to measure the timing as an attacker
True, I'm not worried about the client-side anyway. You are 100% compromised if you get a malware on your machine anyway.
12:32
@TerryChia I've not read the scroll back, but the attacker doesn't need to be on your box to exploit a timing attack.
13:00
Any idea how to create a certificate that is accepted for a TLS server (openssl s_server) using ECDH/RSA key exchange (like ECDH-RSA-AES128-SHA)? The openssl mailing list mentions that I need to have a keyAgreement usage and an "appropriate" curve. What is this curve? I have tried prime192v1 to no avail.
at the certificate level there shouldn't be a difference (though some servers might require bundling certificate and DH parameters in one file)
You'll need to specify either conventional DH params for DHE, or an elliptic curve for ECDHE. But I'm not familiar with your specific server.
For ECDHE I'd use NIST P-256
This is ECDH, not ECDHE. s_server is a test server provided by OpenSSL, nginx has the same issue with these ciphers (openssl ciphers -V | grep ECDH-RSA)
I hope it is not a bug in openssl, but rather my own mistaken/oversight
somebody actually uses ECDH? oO
I don't know, I found it in the ciphers list and want to have a test server that exposes all available servers for testing Wireshark
13:57
@Lekensteyn For this cipher suite, you need the certificate to contain an elliptic-curve key, and be signed by a CA which uses RSA.
You will have a hard time finding a client (browser) which can use that, though.
At least IE and Firefox will not use anything else than P-256 or P-384; that's the two "NSA suite B" curves, i.e. the bare minimum that must be implemented to claim "ECC support" in a US Federal way.
And then, I am not sure they would accept to decode or use a certificate with an ECDH public key.
@ThomasPornin So write your own browser. I'm sure it can't be that hard. :P
Apparently, Microsoft Schannel (the SSL support in Windows, used at least by IE) knows of no "DH" or "ECDH" cipher suite, only "DHE" and "ECDHE".
14:40
PBKDF2-HMAC-SHAx is so silly
 
1 hour later…
16:07
The rogue @Rory strikes again
You closed a question just as I was about to post my answer
16:47
wonder why .net's CSP and CNG crypto functions have such a huge per-call overhead. For SHA512's ComputeHash it's around 10k cycles using CNG and 100k cycles using CSP
16:58
@ThomasPornin Have you kept your answer? I have a feeling the question could be reworked into something useful - it is just extraordinarily broad as it currently stands.
@RoryAlsop Yep, still have it.
If you reopen, I can just click and there it goes.
if so I'll do it right now
@ThomasPornin So if I edit it as the OP suggests to read "what are the default..." would that work?
@CodesInChaos When some manage code calls native code, the .NET VM inspects the whole stack of the calling thread, before and after the call, to make sure that it was not altered.
So the overhead is huge.
@RoryAlsop Actually my answer covers it already, I believe.
oh - I had edited that line in and reopened - good to go
@RoryAlsop ... and done.
17:12
Thanks - and again, my apologies - it appeared exactly when I was doing a quick morning review :-)
@RoryAlsop No need to apology; it is a known defect of the site that it does NOT have a flag "warning, Bear answer is currently being written".
7
@ThomasPornin hahahaha - I should just assume that is the case where question includes crypto of some kind
17:33
@ThomasPornin Overhead of calling OpenSSL is much smaller
@CodesInChaos There is an attribute which can be declared, and which tells to the VM that such a check is not needed. I hypothesize that the Microsoft people forgot to specify it for their own usage.
I remember getting a 10x speedup with OpenSSL with MD5 and short messages.
17:56
@ThomasPornin Didn't we come to conclusion once it'd be best if you add a comment "bear territory" to the questions, so we all know we needn't bother posting puny answers? It should stop mods from closing the question too, I mean, if you have an answer to it, then it clearly shouldn't be closed and is a great question! :)
Most annoying part about C# crypto code is converting between bytes and integers, especially when operating on incomplete blocks.
 
4 hours later…
22:00
@ThomasPornin Thank you for the pointer, now that I use an RSA root CA for signing the EC certificate, ECDH-RSA works. What is the role of the root CA in this EC certificate? Are the public keys of this RSA CA somehow used for ECDH-RSA?
@Lekensteyn The CA key serves only to validate the server's certificate (i.e. to verify the signature on the certificate).
The indication of the CA key type in the cipher suite is a remnant from older times
It was supposed that a reduced TLS client would support only one type of signature algorithm and would specify that to the server, in case the server owns several certificates, signed by the same CA but with different keys of different types.
At that time, RSA was still patented, so the US federal government was pushing DSA + DH.
Therefore some people assumed that "normal" CA may have a RSA key and a DSA key, and would grant two certificates to a server.
In practice (now, and already at that time), everybody uses RSA, nobody uses DSA.
(at least for signing certificates)
@CodesInChaos Right now, I find that the most annoying part about C# and crypto is that Mono's BigInteger implementation is buggy.
So, the "RSA" in "ECDH-RSA" refers to the "Signature Algorirthm" field of a X509 certificate? And since a self-signed EC certificate does not have a RSA cipher, for this reason it cannot be used for ECDH-RSA right?
22:15
@ThomasPornin In what way is it buggy?
@CodesInChaos (BigInteger.One << 64) >> 32
Should yield 4294967296, returns 4294967297
@Lekensteyn Yes, that's the theory. For the practice... it depends. Maybe the client and the server can use any kind of signature on the certificate and say "ECDH-RSA" like they would say "ECDH-Whatever". Or maybe not.
Wouldn't annoy me too much, I already suffer from not-invented-here syndrome. Custom BigInteger here I come.
@CodesInChaos Ah AH ! Turns out the package in Ubuntu is out of date.
@CodesInChaos It so happens that I am also writing my custom BigInteger, which I test against the standard one.
Spent today writing my own SHA-512 implementation. 30% faster than SHA512Managed
With a Mono 3.2.1 for MacOS X, the bug is no longer there.
@CodesInChaos Yeah, you may also find that SHA256Managed is not the fastest ever either.
22:31
RfcDeriveBytes being slow is probably the most annoying crypto performance issue with .net
can't afford reasonable iteration counts with such an implementation

« first day (1004 days earlier)      last day (4174 days later) »