mirror of
https://github.com/marcogll/passkit-generator.git
synced 2026-03-15 18:25:24 +00:00
Removed Schemas.Manifest
This commit is contained in:
@@ -481,8 +481,9 @@ export default class PKPass extends Bundle {
|
||||
}
|
||||
|
||||
private [createManifestSymbol]() {
|
||||
return Object.entries(this[filesSymbol]).reduce<Schemas.Manifest>(
|
||||
(acc, [fileName, buffer]) => {
|
||||
return Object.entries(this[filesSymbol]).reduce<{
|
||||
[key: string]: string;
|
||||
}>((acc, [fileName, buffer]) => {
|
||||
const hashFlow = forge.md.sha1.create();
|
||||
|
||||
hashFlow.update(buffer.toString("binary"));
|
||||
@@ -491,9 +492,7 @@ export default class PKPass extends Bundle {
|
||||
...acc,
|
||||
[fileName]: hashFlow.digest().toHex(),
|
||||
};
|
||||
},
|
||||
{},
|
||||
);
|
||||
}, {});
|
||||
}
|
||||
|
||||
private [closePassSymbol]() {
|
||||
|
||||
@@ -21,9 +21,6 @@ import { Semantics } from "./SemanticTags";
|
||||
|
||||
const schemaDebug = debug("Schema");
|
||||
|
||||
export interface Manifest {
|
||||
[key: string]: string;
|
||||
}
|
||||
|
||||
/* export interface Certificates {
|
||||
wwdr?: string;
|
||||
|
||||
@@ -5,12 +5,12 @@ import type * as Schemas from "./schemas";
|
||||
* Generates the PKCS #7 cryptografic signature for the manifest file.
|
||||
*
|
||||
* @method create
|
||||
* @params {Object} manifest - Manifest content.
|
||||
* @returns {Buffer}
|
||||
* @params manifest - Manifest content.
|
||||
* @returns
|
||||
*/
|
||||
|
||||
export function create(
|
||||
manifest: Schemas.Manifest,
|
||||
manifest: { [key: string]: string },
|
||||
certificates: Schemas.CertificatesSchema,
|
||||
): Buffer {
|
||||
const signature = forge.pkcs7.createSignedData();
|
||||
|
||||
Reference in New Issue
Block a user