curl -X 'POST' "$VEZA_URL/api/v1/assessments/query_spec:nodes?page_token-page_size=1" \
-H "authorization: Bearer $VEZA_TOKEN" \
-d '{
"node_relationship_type": "EFFECTIVE_ACCESS",
"query_type": "SOURCE_TO_DESTINATION",
"include_nodes": true,
"no_relation": false,
"source_node_types": {
"nodes": [
{
"node_type": "OktaUser",
"condition_expression": {
"specs": [
{
"id": "b952cf69-5e31-42e5-ae66-372a45b2045b",
"property": "mfa_active",
"fn": "EQ",
"value": false,
"not": false
}
],
"operator": "AND"
}
}
]
},
"destination_node_types": {
"nodes": [
{
"node_type": "S3Bucket",
"condition_expression": {
"specs": [
{
"id": "b78d3e44-0272-4023-ba34-33abaf608e7e",
"property": "block_public_acls",
"fn": "EQ",
"value": false,
"not": false
}
],
"operator": "AND"
}
}
]
}
}'{
"values": [
{
"id": "00upa6s0hSGtl1eGL5d5",
"type": "OktaUser",
"properties": {
"created_at": "2020-11-12T20:56:34Z",
"datasource_id": "dev-5150036.okta.com",
"email": "[email protected]",
"first_name": "Abel",
"idp_unique_id": "[email protected]",
"is_active": true,
"last_name": "Maclead",
"login": "[email protected]",
"mfa_active": false,
"name": "[email protected]",
"provider_id": "dev-5150036.okta.com",
"status": "STAGED",
"updated_at": "2020-11-12T20:56:34Z"
},
"destination_node_count": 5,
"permissions": [],
"engagement_access_stats": null,
"access_stats": null,
"destination_node_ids": [],
"risk_level": "WARNING",
"raw_permissions": [],
"effective_permissions": []
}
],
"path_values": [],
"next_page_token": "eyJGaXJzdCI6eyJkdXBsaWNhdGlvbl9zY29wZV9pZCI6IjQwZjFlZGZiLWQ1Y2UtNGU4ZC1hNWVmLWY2MzhmMDgxYzMzYiIsImlkIjoiMDB1Nmg4cnI2dkFzSUJqMW41ZDciLCJsb3dlcl9uYW1lIjoiYWFyb24uYmluZm9yZEB2ZXphdGVzdC5jb20ifSwiTGFzdCI6eyJkdXBsaWNhdGlvbl9zY29wZV9pZCI6IjQwZjFlZGZiLWQ1Y2UtNGU4ZC1hNWVmLWY2MzhmMDgxYzMzYiIsImlkIjoiMDB1cGE2czBoU0d0bDFlR0w1ZDUiLCJsb3dlcl9uYW1lIjoiYWJlbF9tYWNsZWFkQGNvb2tpZWRlbW8ub25taWNyb3NvZnQuY29tIn19",
"has_more": true
}curl -X 'POST' "$VEZA_URL/api/v1/assessments/query_spec:destination_nodes?page_size=0&page_token=" \
-H "authorization: Bearer $VEZA_TOKEN" \
-d '{
"spec": {
"node_relationship_type": "EFFECTIVE_ACCESS",
"query_type": "SOURCE_TO_DESTINATION",
"include_nodes": true,
"no_relation": false,
"source_node_types": {
"nodes": [
{
"node_type": "OktaUser",
"id": "StartNode",
"condition_expression": {
"specs": [
{
"id": "b952cf69-5e31-42e5-ae66-372a45b2045b",
"property": "mfa_active",
"fn": "EQ",
"value": false,
"not": false
}
],
"operator": "AND"
}
}
]
},
"destination_node_types": {
"nodes": [
{
"node_type": "S3Bucket",
"id": "EndNode",
"condition_expression": {
"specs": [
{
"id": "b78d3e44-0272-4023-ba34-33abaf608e7e",
"property": "block_public_acls",
"fn": "EQ",
"value": false,
"not": false
}
],
"operator": "AND"
}
}
]
}
},
"source_node_id": "00upa6s0hSGtl1eGL5d5"
}'{
"values": [
{
"id": "arn:aws:s3:::cct-cct02-engineering",
"type": "S3Bucket",
"properties": {
"allows_acls": true,
"aws_account_id": "123456789012",
"block_public_access_enabled": false,
"block_public_acls": false,
"block_public_policy": false,
"created_at": "2021-03-18T08:26:23Z",
"datasource_id": "123456789012:s3",
"default_encryption_enabled": true,
"default_retention_mode": "DISABLED",
"has_public_policy": true,
"hosts_website": false,
"ignore_public_acls": false,
"name": "cct-cct02-engineering",
"object_lock_enabled": false,
"object_ownership_controls": "ObjectWriter",
"provider_id": "123456789012",
"region": "us-east-2",
"replication_rules_count": 0,
"request_payer": "BucketOwner",
"restrict_public_buckets": false,
"server_access_logs_enabled": false
},
"destination_node_count": 0,
"permissions": [
{
"id": "arn:aws:iam::123456789012:role/FederatedS3::eperm::123456789012/S3Bucket/affd3e3cd4f3d7f544628ecce27415ae13a984bb",
"type": "AwsIamEffectivePermission",
"properties": {
"aws_account_id": "123456789012",
"datasource_id": "123456789012::eperm::123456789012:s3",
"name": "Read",
"permissions": [
"s3:GetObject",
"s3:GetObjectVersion"
],
"provider_id": "123456789012"
},
"destination_node_count": 0,
"permissions": [],
"engagement_access_stats": null,
"access_stats": null,
"destination_node_ids": [],
"risk_level": "NONE",
"raw_permissions": [],
"effective_permissions": []
},
{
"id": "arn:aws:iam::123456789012:role/FederatedRedshiftAndS3::eperm::123456789012/S3Bucket/affd3e3cd4f3d7f544628ecce27415ae13a984bb",
"type": "AwsIamEffectivePermission",
"properties": {
"aws_account_id": "123456789012",
"datasource_id": "123456789012::eperm::123456789012:s3",
"name": "Read",
"permissions": [
"s3:GetObject",
"s3:GetObjectVersion"
],
"provider_id": "123456789012"
},
"destination_node_count": 0,
"permissions": [],
"engagement_access_stats": null,
"access_stats": null,
"destination_node_ids": [],
"risk_level": "NONE",
"raw_permissions": [],
"effective_permissions": []
}
],
"engagement_access_stats": null,
"access_stats": null,
"destination_node_ids": [],
"risk_level": "CRITICAL",
"raw_permissions": [
"s3:GetObject",
"s3:GetObjectVersion"
],
"effective_permissions": [
"Read"
]
}
],
"path_values": [],
"next_page_token": "",
"has_more": false
}curl 'https://<baseUrl>/api/v1/assessments/queries/ab5b66df-6873-4e53-98e5-aa55b88c76bd:nodes?page_size=100' \
-H 'authorization: <authToken>'curl 'https://<baseUrl>/api/v1/assessments/queries/ab5b66df-6873-4e53-98e5-aa55b88c76bd:result' \
-H 'authorization: Bearer <authToken>'{
"values": [
{
"id": "arn:aws:s3:::cct-cct01-finance",
"type": "S3Bucket",
"properties": {
"block_public_acls": false,
"name": "cct-cct01-finance"
},
"destination_node_count": 0,
"permissions": []
}
],
"next_page_token": "MTAw",
"has_more": false
}{"result_type":"number","number_value":"1"}