ryantenney / passkit4j

Java library for generating Apple Passbook (.pkpass) files

Home Page:http://www.ryantenney.com/passkit4j/

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Why exactly one alias?

otaviomacedo opened this issue · comments

Why does the method PassSigningUtil.firstAlias require exactly one alias? I am trying to generate p12 files, but they are always generated with two aliases.

So that there isn't any question about which key/cert is being used. If there are multiple aliases, specify the correct one with alias(String)

I had the same problem. In my case It worked only specifying as alias the name of the key inside the .p12 certificate.

There are several options for specifying the alias:
alias(String) - if the p12 file contains more than one alias and the privateKey and signingCertificate aliases are the same
signingCertificateAlias(String) - specify the signing certificate alias
privateKeyAlias(String) - specify the private key alias