-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Signed-off-by: mariobassem <[email protected]>
- Loading branch information
1 parent
3dc1fc7
commit aa5d780
Showing
5 changed files
with
109 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,20 @@ | ||
module zos | ||
|
||
struct GatewayFQDNProxy { | ||
tls_passthrough bool | ||
backends []string | ||
network ?string | ||
fqdn string | ||
} | ||
|
||
pub fn (g GatewayFQDNProxy) challenge() string { | ||
mut output := '' | ||
output += g.fqdn | ||
output += '${g.tls_passthrough}' | ||
for b in g.backends { | ||
output += b | ||
} | ||
output += g.network or { '' } | ||
|
||
return output | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,20 @@ | ||
module zos | ||
|
||
struct GatewayNameProxy { | ||
tls_passthrough bool | ||
backends []string | ||
network ?string | ||
name string | ||
} | ||
|
||
pub fn (g GatewayNameProxy) challenge() string { | ||
mut output := '' | ||
output += g.name | ||
output += '${g.tls_passthrough}' | ||
for b in g.backends { | ||
output += b | ||
} | ||
output += g.network or { '' } | ||
|
||
return output | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,7 @@ | ||
module zos | ||
|
||
pub struct PublicIP4 {} | ||
|
||
pub fn (p PublicIP4) challenge() string { | ||
return '' | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,48 @@ | ||
module zos | ||
|
||
pub struct QuantumSafeFS { | ||
cache u64 | ||
config QuantumSafeFSConfig | ||
} | ||
|
||
pub struct QuantumSafeFSConfig { | ||
minimal_shards u32 | ||
expected_shards u32 | ||
redundant_groups u32 | ||
redundant_nodes u32 | ||
max_zdb_data_dir_size u32 | ||
encryption Encryption | ||
meta QuantumSafeMeta | ||
goups []ZDBGroup | ||
compression QuantumCompression | ||
} | ||
|
||
pub struct Encryption { | ||
algorithm string | ||
key []u8 // TODO: how to create challenge | ||
} | ||
|
||
pub struct QuantumSafeMeta { | ||
type_ string [json: 'type'] | ||
config QuantumSafeConfig | ||
} | ||
|
||
pub struct ZDBGroup { | ||
backends []ZDBBackend | ||
} | ||
|
||
pub struct ZDBBackend { | ||
address string | ||
namespace string | ||
password string | ||
} | ||
|
||
pub struct QuantumCompression { | ||
algorithm string | ||
} | ||
|
||
pub struct QuantumSafeConfig { | ||
prefix string | ||
encryption Encryption | ||
backends []ZDBBackend | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,14 @@ | ||
module zos | ||
|
||
pub struct ZLogs { | ||
zmachine string | ||
output string | ||
} | ||
|
||
pub fn (z ZLogs) challenge() string { | ||
mut output := '' | ||
output += z.zmachine | ||
output += z.output | ||
|
||
return output | ||
} |