On 29 Mar 2011, at 12:26 PM, Chris Ridd wrote: > liblber can only decode the restricted BER defined for use with LDAP. In > particular, no indefinite length encoding, strings can't be constructed, etc. > The lber-decode man page mentions this at the top. > > Given this is all likely to be part of security data, I'd say use the crypto > libraries and/or OpenSSL to crack it apart.
If the security data is in DER, then lber's restricted subset of BER might still suffice. (I haven't looked.) But yes, linking openssl and using d2i_ASN1_type_bytes() and either ASN1_STRING_to_UTF8() or mapping the ASN.1 string types to (Core)Foundation string encodings seems like an easy(ish) way to get correct behavior. _______________________________________________ Cocoa-dev mailing list (Cocoa-dev@lists.apple.com) Please do not post admin requests or moderator comments to the list. Contact the moderators at cocoa-dev-admins(at)lists.apple.com Help/Unsubscribe/Update your Subscription: http://lists.apple.com/mailman/options/cocoa-dev/archive%40mail-archive.com This email sent to arch...@mail-archive.com