sshpiper/plugin/yaml/schema.json
Boshi Lian 39f5eef98b
Refactor YAML schema to support multiple authorized keys and known hosts (#463)
* add coverage for go proxy

* Refactor CLI flag name for allowed proxy addresses

* Refactor YAML schema to support multiple authorized keys and known hosts

* add testcases

* Refactor YAML schema to support multiple authorized keys and known hosts

* go fmt

* go fmt
2024-10-20 00:20:40 -07:00

138 lines
No EOL
3.9 KiB
JSON

{
"$schema": "http://json-schema.org/draft-06/schema#",
"$ref": "#/definitions/sshpiperd",
"definitions": {
"sshpiperd": {
"type": "object",
"additionalProperties": false,
"properties": {
"version": {
"type": "string"
},
"pipes": {
"type": "array",
"items": {
"$ref": "#/definitions/pipe"
}
}
},
"required": [
"pipes",
"version"
]
},
"pipe": {
"type": "object",
"additionalProperties": false,
"properties": {
"from": {
"type": "array",
"items": {
"$ref": "#/definitions/from"
}
},
"to": {
"$ref": "#/definitions/to"
}
},
"required": [
"from",
"to"
]
},
"from": {
"type": "object",
"additionalProperties": false,
"properties": {
"username": {
"type": "string"
},
"username_regex_match": {
"type": "boolean"
},
"authorized_keys": {
"oneOf": [
{
"type": "array",
"items": {
"type": "string"
}
},
{
"type": "string"
}
]
},
"authorized_keys_data": {
"oneOf": [
{
"type": "array",
"items": {
"type": "string"
}
},
{
"type": "string"
}
]
}
},
"required": [
"username"
]
},
"to": {
"type": "object",
"additionalProperties": false,
"properties": {
"host": {
"type": "string"
},
"username": {
"type": "string"
},
"ignore_hostkey": {
"type": "boolean"
},
"password": {
"type": "string"
},
"private_key": {
"type": "string"
},
"private_key_data": {
"type": "string"
},
"known_hosts": {
"oneOf": [
{
"type": "array",
"items": {
"type": "string"
}
},
{
"type": "string"
}
]
},
"known_hosts_data": {
"oneOf": [
{
"type": "array",
"items": {
"type": "string"
}
},
{
"type": "string"
}
]
}
},
"required": [
"host"
]
}
}
}