Definitions for @turbot/aws-securityhub

hub

{
"type": "object",
"properties": {
"HubArn": {
"$ref": "#/definitions/hubAka"
},
"SubscribedAt": {
"type": "string"
},
"Tags": {
"$ref": "aws#/definitions/tagsMap"
},
"turbot": {
"type": "object",
"properties": {
"akas": {
"type": "array",
"items": {
"$ref": "#/definitions/hubAka"
}
},
"title": {
"const": "default"
},
"tags": {
"$ref": "aws#/definitions/tagsMap"
},
"custom": {
"type": "object",
"properties": {
"aws": {
"$ref": "aws#/definitions/awsMetadata"
},
"createTimestamp": {
"$ref": "turbot#/definitions/isoTimestamp"
}
}
}
}
}
},
"additionalProperties": true,
"tests": [
{
"description": "Valid - All properties",
"input": {
"HubArn": "arn:aws:securityhub:us-west-2:560741234067:hub/default",
"SubscribedAt": "2019-11-26T14:40:14.036Z",
"Tags": {
"Key1": "tom2",
"Key3": "tom3",
"harry": "potter",
"Value": "potter",
"Value3": "Jerry3",
"Value1": "Jerry2",
"Key7": "tom7",
"Value8": "Jerry7",
"Key": "harry"
},
"turbot": {
"akas": [
"arn:aws:securityhub:us-west-2:560741234067:hub/default"
],
"title": "default",
"custom": {
"aws": {
"accountId": 560741234067,
"regionName": "us-west-2"
}
}
}
}
}
],
".turbot": {
"uri": "tmod:@turbot/aws-securityhub#/definitions/hub",
"modUri": "tmod:@turbot/aws-securityhub"
}
}

hubAka

{
"type": "string",
"pattern": "^arn:aws(-us-gov|-cn)?:securityhub:[a-z]{2}(-gov)?-[a-z]+-[0-9]{1}:[0-9]{12}:hub/default",
"tests": [
{
"description": "base",
"input": "arn:aws:securityhub:us-west-2:560741234067:hub/default"
},
{
"description": "invalid aka",
"input": "arn:aws:security:us-west-2:560741234067:hub/default1234",
"expected": false
}
],
".turbot": {
"uri": "tmod:@turbot/aws-securityhub#/definitions/hubAka",
"modUri": "tmod:@turbot/aws-securityhub"
}
}

regionName

{
"type": "string",
"enum": [
"ap-northeast-1",
"ap-northeast-2",
"ap-south-1",
"ap-southeast-1",
"ap-southeast-2",
"ca-central-1",
"eu-central-1",
"eu-west-1",
"eu-west-2",
"eu-west-3",
"sa-east-1",
"us-east-1",
"us-east-2",
"us-west-1",
"us-west-2"
],
"tests": [
{
"input": "us-east-1"
},
{
"description": "invalid - usea1",
"input": "usea1",
"expected": false
},
{
"description": "invalid - au-north-1",
"input": "au-north-1",
"expected": false
}
],
".turbot": {
"uri": "tmod:@turbot/aws-securityhub#/definitions/regionName",
"modUri": "tmod:@turbot/aws-securityhub"
}
}

securityHub

{
"allOf": [
{
"$ref": "turbot#/definitions/service"
},
{
"type": "object",
"properties": {
"name": {
"const": "SecurityHub"
},
"turbot": {
"type": "object",
"properties": {
"akas": {
"type": "array",
"items": {
"$ref": "#/definitions/securityHubAka"
}
},
"title": {
"const": "SecurityHub"
},
"custom": {
"type": "object",
"properties": {
"aws": {
"$ref": "aws#/definitions/awsMetadata"
}
}
}
}
}
},
"additionalProperties": true,
"tests": [
{
"description": "All valid properties",
"input": {
"name": "SecurityHub",
"turbot": {
"akas": [
"arn:aws:securityhub:us-east-1:123456789012"
],
"title": "SecurityHub",
"custom": {
"aws": {
"accountId": 123456789012,
"regionName": "us-east-1"
}
}
}
}
}
]
}
],
".turbot": {
"uri": "tmod:@turbot/aws-securityhub#/definitions/securityHub",
"modUri": "tmod:@turbot/aws-securityhub"
}
}

securityHubAka

{
"type": "string",
"pattern": "^arn:aws(-us-gov|-cn)?:securityhub:[a-z]{2}(-gov)?-[a-z]+-[0-9]{1}:[0-9]{12}",
"tests": [
{
"description": "base",
"input": "arn:aws:securityhub:us-east-1:123123123123"
},
{
"description": "invalid aka",
"input": "arn:aws:securityhub111:us-east-1:123123123123",
"expected": false
}
],
".turbot": {
"uri": "tmod:@turbot/aws-securityhub#/definitions/securityHubAka",
"modUri": "tmod:@turbot/aws-securityhub"
}
}

securityHubSupportedRegions

{
"type": "array",
"items": {
"$ref": "#/definitions/regionName"
},
"minItems": 1,
"example": [
[
"us-east-2",
"us-east-1"
]
],
"default": [
"ap-northeast-1",
"ap-northeast-2",
"ap-south-1",
"ap-southeast-1",
"ap-southeast-2",
"ca-central-1",
"eu-central-1",
"eu-west-1",
"eu-west-2",
"eu-west-3",
"sa-east-1",
"us-east-1",
"us-east-2",
"us-west-1",
"us-west-2"
],
"tests": [
{
"description": "one region",
"input": [
"us-east-1"
]
},
{
"description": "all supported regions",
"input": [
"ap-northeast-1",
"ap-northeast-2",
"ap-south-1",
"ap-southeast-1",
"ap-southeast-2",
"ca-central-1",
"eu-central-1",
"eu-west-1",
"eu-west-2",
"eu-west-3",
"sa-east-1",
"us-east-1",
"us-east-2",
"us-west-1",
"us-west-2"
]
},
{
"description": "invalid - no regions",
"input": [],
"expected": false
}
],
".turbot": {
"uri": "tmod:@turbot/aws-securityhub#/definitions/securityHubSupportedRegions",
"modUri": "tmod:@turbot/aws-securityhub"
}
}