-
Notifications
You must be signed in to change notification settings - Fork 388
/
bundle.h
43 lines (36 loc) · 1.29 KB
/
bundle.h
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
#pragma once
#include "common/common.h"
#include "common/json.h"
#include "openssl.h"
#include <vector>
class ZAppBundle {
public:
ZAppBundle();
public:
bool SignFolder(ZSignAsset *pSignAsset, const string &strFolder,
const string &strBundleID, const string &strBundleVersion,
const string &strDisplayName,
const vector<string> &arrDyLibFiles, bool bForce,
bool bWeakInject, bool bEnableCache);
private:
bool SignNode(JValue &jvNode);
void GetNodeChangedFiles(JValue &jvNode);
void GetChangedFiles(JValue &jvNode, vector<string> &arrChangedFiles);
void GetPlugIns(const string &strFolder, vector<string> &arrPlugIns);
private:
bool FindAppFolder(const string &strFolder, string &strAppFolder);
bool GetObjectsToSign(const string &strFolder, JValue &jvInfo);
bool GetSignFolderInfo(const string &strFolder, JValue &jvNode,
bool bGetName = false);
private:
bool GenerateCodeResources(const string &strFolder, JValue &jvCodeRes);
void GetFolderFiles(const string &strFolder, const string &strBaseFolder,
set<string> &setFiles);
private:
bool m_bForceSign;
bool m_bWeakInject;
vector<string> arrDyLibPaths;
ZSignAsset *m_pSignAsset;
public:
string m_strAppFolder;
};