Depreciated ByteArray function in Switch 2017 update 2

Post Reply
dkelly
TOP CONTRIBUTOR
Posts: 628
Joined: Mon Nov 29, 2010 8:45 pm
Location: Alpharetta GA USA
Contact:

Depreciated ByteArray function in Switch 2017 update 2

Post by dkelly »

The ByteArray function generateSignature( privateKeyPath : String ) was "depreciated" by Enfocus in Switch 2017 Update 2. Normally depreciated means it is no longer recommend to be used and will be removed in future updates. However, in this case it means Enfocus removed the function entirely. The documentation that shipped with Switch 2017 Update 2 beta did not contain this change.

The new function is getSignature( privateKeyPath : String, hashFunction : String, privateKeyPassword : String).

Where generateSignature() used the internal private key in Switch by default, getSignature() requires your own private key file.

To generate a PKCS#8 private key, run the following commands:

Code: Select all

$ openssl genrsa -des3 -out myprivatekey.pem 2048
$ openssl pkcs8 -topk8 -inform PEM -outform PEM -in myprivatekey.pem -out appstore.key
enfocus
Newbie
Posts: 11
Joined: Fri May 12, 2017 9:10 am

Re: Depreciated ByteArray function in Switch 2017 update 2

Post by enfocus »

We indeed deprecated generateSignature() in Switch 2017, update 2 and advise to use the newly introduced getSignature() instead. However, we did not remove generateSignature(). The latest nightly builds of Switch 2017, update 2 have been tested and we can't find an issue with generateSignature().

Most likely there was an issue with the generateSignature() function in previous nightly builds and it has been fixed in the meantime.
Post Reply