Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion packages/fints/src/segments/hitans.ts
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ export class HITANS extends SegmentClass(HITANSProps) {
protected serialize(): string[][] { throw new Error("Not implemented."); }

protected deserialize(input: string[][]) {
if (![1, 2, 3, 4, 5, 6].includes(this.version)) {
if (![1, 2, 3, 4, 5, 6, 7].includes(this.version)) {
throw new Error(`Unimplemented TAN method version ${this.version} encountered.`);
}
const [
Expand Down
44 changes: 44 additions & 0 deletions packages/fints/src/tan-method.ts
Original file line number Diff line number Diff line change
Expand Up @@ -129,6 +129,35 @@ tanMethodArgumentMap.set(6, [
"supportedMediaNumber",
]);

tanMethodArgumentMap.set(7, [
"securityFunction",
"tanProcess",
"techId",
"dkId",
"dkVersion",
"name",
"maxLengthInput",
"allowedFormat",
"textReturnvalue",
"maxLengthReturnvalue",
"multiple",
"tanTimeDialogAssociation",
"cancellable",
"smsChargeAccountRequired",
"principalAccountRequired",
"challengeClassRequired",
"challengeStructured",
"initializationMode",
"descriptionRequired",
"hhdUcRequired",
"supportedMediaNumber",
"maxStatusRequestDecoupled",
"waitTimeBeforeFirstStatusRequest",
"waitTimeBeforeNextStatusRequest",
"manual",
"automated",
]);

export class TanMethod {
public allowedFormat?: string;
public cancellable?: boolean;
Expand All @@ -154,7 +183,14 @@ export class TanMethod {
public textReturnvalue?: string;
public zkaId?: string;
public zkaVersion?: string;
public dkId?: string;
public dkVersion?: string;
public version?: number;
public maxStatusRequestDecoupled?: number;
public waitTimeBeforeFirstStatusRequest?: number;
public waitTimeBeforeNextStatusRequest?: number;
public manual?: boolean;
public automated?: boolean;

constructor(version: number, config?: string[]) {
this.version = version;
Expand Down Expand Up @@ -187,5 +223,13 @@ export class TanMethod {
this.textReturnvalue = map.get("textReturnvalue");
this.zkaId = map.get("zkaId");
this.zkaVersion = map.get("zkaVersion");
this.dkId = map.get("dkId");
this.dkVersion = map.get("dkVersion");
this.maxStatusRequestDecoupled = Parse.num(map.get("maxStatusRequestDecoupled"));
this.waitTimeBeforeFirstStatusRequest = Parse.num(map.get("waitTimeBeforeFirstStatusRequest"));
this.waitTimeBeforeNextStatusRequest = Parse.num(map.get("waitTimeBeforeNextStatusRequest"));
this.manual = Parse.bool(map.get("manual"));
this.automated = Parse.bool(map.get("automated"));

}
}