sm: Rework the PKCS#12 parser to support DFN issued keys.
* sm/minip12.c (struct p12_parse_ctx_s): New. Use this instead of passing several parameters to most functions. (parse_pag_data): Factor things out to ... parse_shrouded_key_bag): new. (parse_cert_bag): New. (parse_bag_data): New. (p12_parse): Setup the parse context.
To support newer pkcs#12 files like those issued by the DFN we need to
support another ordering of data elements. This rework reflects the
P12 data structure a bit better than our old ad-hoc hacks. Tests could
only be done with the certificate parts and not the encrypted private
keys.
- GnuPG-bug-id: T6037