feat: Certificate request form (#7)
* wip: first draft cert request * feat: form for cert request * fix: add missing fields * add app bar * Give alt names list more space * add missing rules
This commit is contained in:
parent
d98f60ab54
commit
f870fc1ac6
7 changed files with 196 additions and 0 deletions
25
frontend/src/types/certificate.d.ts
vendored
Normal file
25
frontend/src/types/certificate.d.ts
vendored
Normal file
|
@ -0,0 +1,25 @@
|
|||
export interface Subject {
|
||||
commonName: string;
|
||||
organization: string;
|
||||
orgUnit: string;
|
||||
country: string;
|
||||
state: string;
|
||||
city: string
|
||||
altNames: string[];
|
||||
}
|
||||
|
||||
export interface Validity {
|
||||
from: Date;
|
||||
to: Date;
|
||||
}
|
||||
|
||||
export interface Extensions {
|
||||
|
||||
}
|
||||
|
||||
export interface Certificate {
|
||||
issuer: Subject;
|
||||
validity: Validity;
|
||||
subject: Subject;
|
||||
extensions: Extensions;
|
||||
}
|
3
frontend/src/types/util.d.ts
vendored
Normal file
3
frontend/src/types/util.d.ts
vendored
Normal file
|
@ -0,0 +1,3 @@
|
|||
export type Validated<T> = {
|
||||
[K in keyof T as `${K}Rules`]: ((val: string) => true | string)[]
|
||||
} & T;
|
Loading…
Add table
Add a link
Reference in a new issue