exposure-keys 1.18.1 → 1.18.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/package.json +11 -8
- package/proto/export.d.ts +152 -109
- package/proto/export.js +423 -194
package/package.json
CHANGED
|
@@ -2,13 +2,13 @@
|
|
|
2
2
|
"author": "Florian Imdahl <git@ffflorian.de>",
|
|
3
3
|
"dependencies": {
|
|
4
4
|
"jszip": "3.10.1",
|
|
5
|
-
"protobufjs": "8.
|
|
5
|
+
"protobufjs": "8.3.0"
|
|
6
6
|
},
|
|
7
7
|
"description": "Temporary Exposure Keys (TEK) library",
|
|
8
8
|
"devDependencies": {
|
|
9
|
-
"protobufjs-cli": "2.
|
|
10
|
-
"tsx": "4.
|
|
11
|
-
"typescript": "6.0.
|
|
9
|
+
"protobufjs-cli": "2.3.0",
|
|
10
|
+
"tsx": "4.22.0",
|
|
11
|
+
"typescript": "6.0.3"
|
|
12
12
|
},
|
|
13
13
|
"engines": {
|
|
14
14
|
"node": ">= 18"
|
|
@@ -34,16 +34,19 @@
|
|
|
34
34
|
"license": "GPL-3.0",
|
|
35
35
|
"name": "exposure-keys",
|
|
36
36
|
"readme": "https://github.com/ffflorian/node-packages#readme",
|
|
37
|
-
"repository":
|
|
37
|
+
"repository": {
|
|
38
|
+
"type": "git",
|
|
39
|
+
"url": "git+https://github.com/ffflorian/node-packages.git"
|
|
40
|
+
},
|
|
38
41
|
"scripts": {
|
|
39
42
|
"build": "yarn build:proto && yarn build:ts",
|
|
40
43
|
"build:proto": "pbjs --t static-module -w commonjs -o proto/export.js proto/export.proto && pbts --out proto/export.d.ts --no-comments proto/export.js",
|
|
41
44
|
"build:ts": "tsc -p tsconfig.build.json",
|
|
42
45
|
"clean": "rm -rf dist",
|
|
43
46
|
"dist": "yarn clean && yarn build",
|
|
44
|
-
"start": "tsx src/cli.ts -d"
|
|
47
|
+
"start": "tsx src/cli.ts -d",
|
|
48
|
+
"test": "vitest run"
|
|
45
49
|
},
|
|
46
50
|
"type": "module",
|
|
47
|
-
"version": "1.18.
|
|
48
|
-
"gitHead": "aa42364cabdedc7bba727430cb686713f4598ce8"
|
|
51
|
+
"version": "1.18.2"
|
|
49
52
|
}
|
package/proto/export.d.ts
CHANGED
|
@@ -1,91 +1,116 @@
|
|
|
1
1
|
import * as $protobuf from "protobufjs";
|
|
2
2
|
import Long = require("long");
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
3
|
+
|
|
4
|
+
export interface ITemporaryExposureKeyExport extends TemporaryExposureKeyExport.$Properties {
|
|
5
|
+
}
|
|
6
|
+
|
|
7
|
+
export class TemporaryExposureKeyExport {
|
|
8
|
+
constructor(properties?: TemporaryExposureKeyExport.$Properties);
|
|
9
|
+
$unknowns?: Uint8Array[];
|
|
10
|
+
startTimestamp: (number|Long);
|
|
11
|
+
endTimestamp: (number|Long);
|
|
12
|
+
region: string;
|
|
13
|
+
batchNum: number;
|
|
14
|
+
batchSize: number;
|
|
15
|
+
signatureInfos: SignatureInfo.$Properties[];
|
|
16
|
+
keys: TemporaryExposureKey.$Properties[];
|
|
17
|
+
revisedKeys: TemporaryExposureKey.$Properties[];
|
|
18
|
+
static create(properties: TemporaryExposureKeyExport.$Shape): TemporaryExposureKeyExport & TemporaryExposureKeyExport.$Shape;
|
|
19
|
+
static create(properties?: TemporaryExposureKeyExport.$Properties): TemporaryExposureKeyExport;
|
|
20
|
+
static encode(message: TemporaryExposureKeyExport.$Properties, writer?: $protobuf.Writer): $protobuf.Writer;
|
|
21
|
+
static encodeDelimited(message: TemporaryExposureKeyExport.$Properties, writer?: $protobuf.Writer): $protobuf.Writer;
|
|
22
|
+
static decode(reader: ($protobuf.Reader|Uint8Array), length?: number): TemporaryExposureKeyExport & TemporaryExposureKeyExport.$Shape;
|
|
23
|
+
static decodeDelimited(reader: ($protobuf.Reader|Uint8Array)): TemporaryExposureKeyExport & TemporaryExposureKeyExport.$Shape;
|
|
24
|
+
static verify(message: { [k: string]: any }): (string|null);
|
|
25
|
+
static fromObject(object: { [k: string]: any }): TemporaryExposureKeyExport;
|
|
26
|
+
static toObject(message: TemporaryExposureKeyExport, options?: $protobuf.IConversionOptions): { [k: string]: any };
|
|
27
|
+
toJSON(): { [k: string]: any };
|
|
28
|
+
static getTypeUrl(prefix?: string): string;
|
|
12
29
|
}
|
|
13
30
|
|
|
14
|
-
export
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
public static decode(reader: ($protobuf.Reader|Uint8Array), length?: number): TemporaryExposureKeyExport;
|
|
28
|
-
public static decodeDelimited(reader: ($protobuf.Reader|Uint8Array)): TemporaryExposureKeyExport;
|
|
29
|
-
public static verify(message: { [k: string]: any }): (string|null);
|
|
30
|
-
public static fromObject(object: { [k: string]: any }): TemporaryExposureKeyExport;
|
|
31
|
-
public static toObject(message: TemporaryExposureKeyExport, options?: $protobuf.IConversionOptions): { [k: string]: any };
|
|
32
|
-
public toJSON(): { [k: string]: any };
|
|
33
|
-
public static getTypeUrl(typeUrlPrefix?: string): string;
|
|
31
|
+
export namespace TemporaryExposureKeyExport {
|
|
32
|
+
interface $Properties {
|
|
33
|
+
startTimestamp?: (number|Long|null);
|
|
34
|
+
endTimestamp?: (number|Long|null);
|
|
35
|
+
region?: (string|null);
|
|
36
|
+
batchNum?: (number|null);
|
|
37
|
+
batchSize?: (number|null);
|
|
38
|
+
signatureInfos?: (SignatureInfo.$Properties[]|null);
|
|
39
|
+
keys?: (TemporaryExposureKey.$Properties[]|null);
|
|
40
|
+
revisedKeys?: (TemporaryExposureKey.$Properties[]|null);
|
|
41
|
+
$unknowns?: Uint8Array[];
|
|
42
|
+
}
|
|
43
|
+
type $Shape = TemporaryExposureKeyExport.$Properties;
|
|
34
44
|
}
|
|
35
45
|
|
|
36
|
-
export interface ISignatureInfo {
|
|
37
|
-
verificationKeyVersion?: (string|null);
|
|
38
|
-
verificationKeyId?: (string|null);
|
|
39
|
-
signatureAlgorithm?: (string|null);
|
|
46
|
+
export interface ISignatureInfo extends SignatureInfo.$Properties {
|
|
40
47
|
}
|
|
41
48
|
|
|
42
|
-
export class SignatureInfo
|
|
43
|
-
constructor(properties?:
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
49
|
+
export class SignatureInfo {
|
|
50
|
+
constructor(properties?: SignatureInfo.$Properties);
|
|
51
|
+
$unknowns?: Uint8Array[];
|
|
52
|
+
verificationKeyVersion: string;
|
|
53
|
+
verificationKeyId: string;
|
|
54
|
+
signatureAlgorithm: string;
|
|
55
|
+
static create(properties: SignatureInfo.$Shape): SignatureInfo & SignatureInfo.$Shape;
|
|
56
|
+
static create(properties?: SignatureInfo.$Properties): SignatureInfo;
|
|
57
|
+
static encode(message: SignatureInfo.$Properties, writer?: $protobuf.Writer): $protobuf.Writer;
|
|
58
|
+
static encodeDelimited(message: SignatureInfo.$Properties, writer?: $protobuf.Writer): $protobuf.Writer;
|
|
59
|
+
static decode(reader: ($protobuf.Reader|Uint8Array), length?: number): SignatureInfo & SignatureInfo.$Shape;
|
|
60
|
+
static decodeDelimited(reader: ($protobuf.Reader|Uint8Array)): SignatureInfo & SignatureInfo.$Shape;
|
|
61
|
+
static verify(message: { [k: string]: any }): (string|null);
|
|
62
|
+
static fromObject(object: { [k: string]: any }): SignatureInfo;
|
|
63
|
+
static toObject(message: SignatureInfo, options?: $protobuf.IConversionOptions): { [k: string]: any };
|
|
64
|
+
toJSON(): { [k: string]: any };
|
|
65
|
+
static getTypeUrl(prefix?: string): string;
|
|
66
|
+
}
|
|
67
|
+
|
|
68
|
+
export namespace SignatureInfo {
|
|
69
|
+
interface $Properties {
|
|
70
|
+
verificationKeyVersion?: (string|null);
|
|
71
|
+
verificationKeyId?: (string|null);
|
|
72
|
+
signatureAlgorithm?: (string|null);
|
|
73
|
+
$unknowns?: Uint8Array[];
|
|
74
|
+
}
|
|
75
|
+
type $Shape = SignatureInfo.$Properties;
|
|
57
76
|
}
|
|
58
77
|
|
|
59
|
-
export interface ITemporaryExposureKey {
|
|
60
|
-
keyData?: (Uint8Array|null);
|
|
61
|
-
transmissionRiskLevel?: (number|null);
|
|
62
|
-
rollingStartIntervalNumber?: (number|null);
|
|
63
|
-
rollingPeriod?: (number|null);
|
|
64
|
-
reportType?: (TemporaryExposureKey.ReportType|null);
|
|
65
|
-
daysSinceOnsetOfSymptoms?: (number|null);
|
|
78
|
+
export interface ITemporaryExposureKey extends TemporaryExposureKey.$Properties {
|
|
66
79
|
}
|
|
67
80
|
|
|
68
|
-
export class TemporaryExposureKey
|
|
69
|
-
constructor(properties?:
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
|
|
76
|
-
|
|
77
|
-
|
|
78
|
-
|
|
79
|
-
|
|
80
|
-
|
|
81
|
-
|
|
82
|
-
|
|
83
|
-
|
|
84
|
-
|
|
85
|
-
|
|
81
|
+
export class TemporaryExposureKey {
|
|
82
|
+
constructor(properties?: TemporaryExposureKey.$Properties);
|
|
83
|
+
$unknowns?: Uint8Array[];
|
|
84
|
+
keyData: Uint8Array;
|
|
85
|
+
transmissionRiskLevel: number;
|
|
86
|
+
rollingStartIntervalNumber: number;
|
|
87
|
+
rollingPeriod: number;
|
|
88
|
+
reportType: TemporaryExposureKey.ReportType;
|
|
89
|
+
daysSinceOnsetOfSymptoms: number;
|
|
90
|
+
static create(properties: TemporaryExposureKey.$Shape): TemporaryExposureKey & TemporaryExposureKey.$Shape;
|
|
91
|
+
static create(properties?: TemporaryExposureKey.$Properties): TemporaryExposureKey;
|
|
92
|
+
static encode(message: TemporaryExposureKey.$Properties, writer?: $protobuf.Writer): $protobuf.Writer;
|
|
93
|
+
static encodeDelimited(message: TemporaryExposureKey.$Properties, writer?: $protobuf.Writer): $protobuf.Writer;
|
|
94
|
+
static decode(reader: ($protobuf.Reader|Uint8Array), length?: number): TemporaryExposureKey & TemporaryExposureKey.$Shape;
|
|
95
|
+
static decodeDelimited(reader: ($protobuf.Reader|Uint8Array)): TemporaryExposureKey & TemporaryExposureKey.$Shape;
|
|
96
|
+
static verify(message: { [k: string]: any }): (string|null);
|
|
97
|
+
static fromObject(object: { [k: string]: any }): TemporaryExposureKey;
|
|
98
|
+
static toObject(message: TemporaryExposureKey, options?: $protobuf.IConversionOptions): { [k: string]: any };
|
|
99
|
+
toJSON(): { [k: string]: any };
|
|
100
|
+
static getTypeUrl(prefix?: string): string;
|
|
86
101
|
}
|
|
87
102
|
|
|
88
103
|
export namespace TemporaryExposureKey {
|
|
104
|
+
interface $Properties {
|
|
105
|
+
keyData?: (Uint8Array|null);
|
|
106
|
+
transmissionRiskLevel?: (number|null);
|
|
107
|
+
rollingStartIntervalNumber?: (number|null);
|
|
108
|
+
rollingPeriod?: (number|null);
|
|
109
|
+
reportType?: (TemporaryExposureKey.ReportType|null);
|
|
110
|
+
daysSinceOnsetOfSymptoms?: (number|null);
|
|
111
|
+
$unknowns?: Uint8Array[];
|
|
112
|
+
}
|
|
113
|
+
type $Shape = TemporaryExposureKey.$Properties;
|
|
89
114
|
|
|
90
115
|
enum ReportType {
|
|
91
116
|
UNKNOWN = 0,
|
|
@@ -97,46 +122,64 @@ export namespace TemporaryExposureKey {
|
|
|
97
122
|
}
|
|
98
123
|
}
|
|
99
124
|
|
|
100
|
-
export interface ITEKSignatureList {
|
|
101
|
-
|
|
125
|
+
export interface ITEKSignatureList extends TEKSignatureList.$Properties {
|
|
126
|
+
}
|
|
127
|
+
|
|
128
|
+
export class TEKSignatureList {
|
|
129
|
+
constructor(properties?: TEKSignatureList.$Properties);
|
|
130
|
+
$unknowns?: Uint8Array[];
|
|
131
|
+
signatures: TEKSignature.$Properties[];
|
|
132
|
+
static create(properties: TEKSignatureList.$Shape): TEKSignatureList & TEKSignatureList.$Shape;
|
|
133
|
+
static create(properties?: TEKSignatureList.$Properties): TEKSignatureList;
|
|
134
|
+
static encode(message: TEKSignatureList.$Properties, writer?: $protobuf.Writer): $protobuf.Writer;
|
|
135
|
+
static encodeDelimited(message: TEKSignatureList.$Properties, writer?: $protobuf.Writer): $protobuf.Writer;
|
|
136
|
+
static decode(reader: ($protobuf.Reader|Uint8Array), length?: number): TEKSignatureList & TEKSignatureList.$Shape;
|
|
137
|
+
static decodeDelimited(reader: ($protobuf.Reader|Uint8Array)): TEKSignatureList & TEKSignatureList.$Shape;
|
|
138
|
+
static verify(message: { [k: string]: any }): (string|null);
|
|
139
|
+
static fromObject(object: { [k: string]: any }): TEKSignatureList;
|
|
140
|
+
static toObject(message: TEKSignatureList, options?: $protobuf.IConversionOptions): { [k: string]: any };
|
|
141
|
+
toJSON(): { [k: string]: any };
|
|
142
|
+
static getTypeUrl(prefix?: string): string;
|
|
102
143
|
}
|
|
103
144
|
|
|
104
|
-
export
|
|
105
|
-
|
|
106
|
-
|
|
107
|
-
|
|
108
|
-
|
|
109
|
-
|
|
110
|
-
public static decode(reader: ($protobuf.Reader|Uint8Array), length?: number): TEKSignatureList;
|
|
111
|
-
public static decodeDelimited(reader: ($protobuf.Reader|Uint8Array)): TEKSignatureList;
|
|
112
|
-
public static verify(message: { [k: string]: any }): (string|null);
|
|
113
|
-
public static fromObject(object: { [k: string]: any }): TEKSignatureList;
|
|
114
|
-
public static toObject(message: TEKSignatureList, options?: $protobuf.IConversionOptions): { [k: string]: any };
|
|
115
|
-
public toJSON(): { [k: string]: any };
|
|
116
|
-
public static getTypeUrl(typeUrlPrefix?: string): string;
|
|
145
|
+
export namespace TEKSignatureList {
|
|
146
|
+
interface $Properties {
|
|
147
|
+
signatures?: (TEKSignature.$Properties[]|null);
|
|
148
|
+
$unknowns?: Uint8Array[];
|
|
149
|
+
}
|
|
150
|
+
type $Shape = TEKSignatureList.$Properties;
|
|
117
151
|
}
|
|
118
152
|
|
|
119
|
-
export interface ITEKSignature {
|
|
120
|
-
signatureInfo?: (ISignatureInfo|null);
|
|
121
|
-
batchNum?: (number|null);
|
|
122
|
-
batchSize?: (number|null);
|
|
123
|
-
signature?: (Uint8Array|null);
|
|
153
|
+
export interface ITEKSignature extends TEKSignature.$Properties {
|
|
124
154
|
}
|
|
125
155
|
|
|
126
|
-
export class TEKSignature
|
|
127
|
-
constructor(properties?:
|
|
128
|
-
|
|
129
|
-
|
|
130
|
-
|
|
131
|
-
|
|
132
|
-
|
|
133
|
-
|
|
134
|
-
|
|
135
|
-
|
|
136
|
-
|
|
137
|
-
|
|
138
|
-
|
|
139
|
-
|
|
140
|
-
|
|
141
|
-
|
|
156
|
+
export class TEKSignature {
|
|
157
|
+
constructor(properties?: TEKSignature.$Properties);
|
|
158
|
+
$unknowns?: Uint8Array[];
|
|
159
|
+
signatureInfo?: (SignatureInfo.$Properties|null);
|
|
160
|
+
batchNum: number;
|
|
161
|
+
batchSize: number;
|
|
162
|
+
signature: Uint8Array;
|
|
163
|
+
static create(properties: TEKSignature.$Shape): TEKSignature & TEKSignature.$Shape;
|
|
164
|
+
static create(properties?: TEKSignature.$Properties): TEKSignature;
|
|
165
|
+
static encode(message: TEKSignature.$Properties, writer?: $protobuf.Writer): $protobuf.Writer;
|
|
166
|
+
static encodeDelimited(message: TEKSignature.$Properties, writer?: $protobuf.Writer): $protobuf.Writer;
|
|
167
|
+
static decode(reader: ($protobuf.Reader|Uint8Array), length?: number): TEKSignature & TEKSignature.$Shape;
|
|
168
|
+
static decodeDelimited(reader: ($protobuf.Reader|Uint8Array)): TEKSignature & TEKSignature.$Shape;
|
|
169
|
+
static verify(message: { [k: string]: any }): (string|null);
|
|
170
|
+
static fromObject(object: { [k: string]: any }): TEKSignature;
|
|
171
|
+
static toObject(message: TEKSignature, options?: $protobuf.IConversionOptions): { [k: string]: any };
|
|
172
|
+
toJSON(): { [k: string]: any };
|
|
173
|
+
static getTypeUrl(prefix?: string): string;
|
|
174
|
+
}
|
|
175
|
+
|
|
176
|
+
export namespace TEKSignature {
|
|
177
|
+
interface $Properties {
|
|
178
|
+
signatureInfo?: (SignatureInfo.$Properties|null);
|
|
179
|
+
batchNum?: (number|null);
|
|
180
|
+
batchSize?: (number|null);
|
|
181
|
+
signature?: (Uint8Array|null);
|
|
182
|
+
$unknowns?: Uint8Array[];
|
|
183
|
+
}
|
|
184
|
+
type $Shape = TEKSignature.$Properties;
|
|
142
185
|
}
|