as3-crypto
as3-crypto copied to clipboard
HTTPS with audio
I'm trying to use this crypto library as part of as3httpclientlib to pass on an audio recording (wav) in the body of an HTTPS request. Unfortunately I'm seeing the following error:
at com.hurlant.util.asn1.type::SetType/fromDERContent()[/Users/timkurvers/Projects/personal/as3.crypto/src/com/hurlant/util/asn1/type/SetType.as:23]
at com.hurlant.util.asn1.type::ASN1Type/fromDER()[/Users/timkurvers/Projects/personal/as3.crypto/src/com/hurlant/util/asn1/type/ASN1Type.as:131]
at com.hurlant.util.asn1.type::SequenceType/fromDERContent()[/Users/timkurvers/Projects/personal/as3.crypto/src/com/hurlant/util/asn1/type/SequenceType.as:56]
at com.hurlant.util.asn1.type::ASN1Type/fromDER()[/Users/timkurvers/Projects/personal/as3.crypto/src/com/hurlant/util/asn1/type/ASN1Type.as:131]
at com.hurlant.util.asn1.type::ChoiceType/fromDER()[/Users/timkurvers/Projects/personal/as3.crypto/src/com/hurlant/util/asn1/type/ChoiceType.as:23]
at com.hurlant.util.asn1.type::SequenceType/fromDERContent()[/Users/timkurvers/Projects/personal/as3.crypto/src/com/hurlant/util/asn1/type/SequenceType.as:32]
at com.hurlant.util.asn1.type::ASN1Type/fromDER()[/Users/timkurvers/Projects/personal/as3.crypto/src/com/hurlant/util/asn1/type/ASN1Type.as:131]
at com.hurlant.util.asn1.type::SequenceType/fromDERContent()[/Users/timkurvers/Projects/personal/as3.crypto/src/com/hurlant/util/asn1/type/SequenceType.as:32]
at com.hurlant.util.asn1.type::ASN1Type/fromDER()[/Users/timkurvers/Projects/personal/as3.crypto/src/com/hurlant/util/asn1/type/ASN1Type.as:131]
at com.hurlant.crypto.cert::X509Certificate/load()[/Users/timkurvers/Projects/personal/as3.crypto/src/com/hurlant/crypto/cert/X509Certificate.as:56]
at com.hurlant.crypto.cert::X509Certificate/getSubjectPrincipal()[/Users/timkurvers/Projects/personal/as3.crypto/src/com/hurlant/crypto/cert/X509Certificate.as:201]
at com.hurlant.crypto.cert::X509CertificateCollection/addCertificate()[/Users/timkurvers/Projects/personal/as3.crypto/src/com/hurlant/crypto/cert/X509CertificateCollection.as:40]
at com.hurlant.crypto.tls::TLSEngine/loadCertificates()[/Users/timkurvers/Projects/personal/as3.crypto/src/com/hurlant/crypto/tls/TLSEngine.as:790]
at com.hurlant.crypto.tls::TLSEngine/parseHandshake()[/Users/timkurvers/Projects/personal/as3.crypto/src/com/hurlant/crypto/tls/TLSEngine.as:352]
at com.hurlant.crypto.tls::TLSEngine/parseOneRecord()[/Users/timkurvers/Projects/personal/as3.crypto/src/com/hurlant/crypto/tls/TLSEngine.as:257]
at com.hurlant.crypto.tls::TLSEngine/parseRecord()[/Users/timkurvers/Projects/personal/as3.crypto/src/com/hurlant/crypto/tls/TLSEngine.as:206]
at com.hurlant.crypto.tls::TLSEngine/dataAvailable()[/Users/timkurvers/Projects/personal/as3.crypto/src/com/hurlant/crypto/tls/TLSEngine.as:166]
I'm guessing there may be some issues encrypting the wav audio data but since I"m not an expert at this, I can't really tell at this point. Before using this fork, I used as3crypto and got the following error:
I DONT KNOW HOW TO HANDLE DER stuff of TYPE 12
Any thoughts?
Cheers. Adam
Hi Adam, thanks for the report. Was there an actual exception thrown? I can only see a stacktrace.
Haven't been handling any Flash projects for the last half year, but I'll see if I can get my development environment up and running again to look into this.
Hey Tim,
Thanks for your fast reply. I actually found another fork of as3crypto that fixed the issue. It's from Henri Torgemane. I'm not sure which fix fixed the issue - think it was something related to one of the base64 conversions.
Thanks, Adam
On Sun, Nov 18, 2012 at 11:41 PM, Tim Kurvers [email protected]:
Hi Adam, thanks for the report. Was there an actual exception thrown? I can only see a stacktrace.
Haven't been handling any Flash projects for the last half year, but I'll see if I can get my development environment up and running again to look into this.
— Reply to this email directly or view it on GitHubhttps://github.com/timkurvers/as3-crypto/issues/7#issuecomment-10503472.
That's an interesting discovery, as Henri's the creator of the original! So that essentially means that one of the 'fixes' in this fork broke stuff.
Could you link to the project you used?