Skip to content

⭐ AWS: 18 new resources, ~70 new fields on existing resources, 23 services#6667

Merged
syrull merged 5 commits intomainfrom
tas50/new_aws
Feb 28, 2026
Merged

⭐ AWS: 18 new resources, ~70 new fields on existing resources, 23 services#6667
syrull merged 5 commits intomainfrom
tas50/new_aws

Conversation

@tas50
Copy link
Copy Markdown
Member

@tas50 tas50 commented Feb 23, 2026

New Resources

  • aws.backup.lifecycle
  • aws.backup.plan
  • aws.backup.plan.advancedBackupSetting
  • aws.backup.plan.rule
  • aws.backup.plan.rule.copyAction
  • aws.ec2.transitgateway
  • aws.ecr.lifecyclePolicy
  • aws.ecr.lifecyclePolicy.rule
  • aws.elb.listener
  • aws.elb.loadbalancer.attribute
  • aws.elb.targetgroup.attributes
  • aws.fsx.volume
  • aws.iam.instanceProfile
  • aws.neptune.snapshot
  • aws.redshift.snapshot
  • aws.s3.bucket.encryptionRule
  • aws.s3.bucket.replicationRule
  • aws.vpc.routetable.route

New Fields on Existing Resources

  • aws.acm.certificate: renewalEligible, signatureAlgorithm
  • aws.cloudfront.distribution: comment
  • aws.cloudwatch.loggroup: dataProtectionStatus, deletionProtectionEnabled
  • aws.cloudwatch.metricsalarm: actionsEnabled
  • aws.codebuild.project: createdAt, encryptionKey, modifiedAt, privilegedMode, projectVisibility, queuedTimeoutInMinutes, serviceRole, timeoutInMinutes
  • aws.dynamodb.table: latestStreamLabel
  • aws.ec2.image: description
  • aws.ec2.instance: bootMode, ipv6Address, sourceDestCheck
  • aws.ec2: transitGateways
  • aws.ecr.repository: lifecyclePolicy (converted from dict to typed resource)
  • aws.ecs.service: enableEcsManagedTags, enableExecuteCommand, healthCheckGracePeriodSeconds, platformFamily, platformVersion, schedulingStrategy
  • aws.ecs.taskDefinition: cpu, memory, registeredAt
  • aws.elasticache.cluster: preferredMaintenanceWindow, replicationGroupLogDeliveryEnabled
  • aws.elasticache.serverlessCache: subnets
  • aws.elb.loadbalancer: instances, ipAddressType, listeners
  • aws.elb.targetgroup: healthyThresholdCount
  • aws.fsx.backup: region
  • aws.fsx.cache: region
  • aws.iam.group: path
  • aws.iam.role: path
  • aws.iam.user: path
  • aws.lambda.function: codeSize, lastUpdateStatus, state, stateReason
  • aws.neptune.cluster: snapshots
  • aws.rds.dbcluster: earliestRestorableTime, engineMode
  • aws.rds.dbinstance: dbClusterIdentifier, dbiResourceId, dedicatedLogVolume, licenseModel, maxAllocatedStorage, storageThroughput
  • aws.redshift.cluster: clusterAvailabilityStatus, ipAddressType, manualSnapshotRetentionPeriod, multiAZ, snapshots, totalStorageCapacityInMegaBytes
  • aws.s3.bucket: encryptionRules, replicationRules
  • aws.sagemaker.notebookinstancedetails: minimumInstanceMetadataServiceVersion, rootAccess, subnet
  • aws.sns.topic: kmsMasterKey
  • aws.sqs.queue: deduplicationScope, fifoThroughputLimit
  • aws.ssm.instance: agentVersion, computerName, lastPingedAt
  • aws.vpc.routetable: routeEntries
aws.backup.plans.first: {
  deletionDate: null
  lastExecutionDate: 2026-02-26 05:33:24.432 +0000 WET
  advancedBackupSettings: []
  region: "us-west-2"
  id: "aws/efs/12345678910"
  name: "aws/efs/automatic-backup-plan"
  versionId: "12345678910"
  arn: "arn:aws:backup:us-west-2:12345678910:backup-plan:aws/efs/12345678910"
  createdAt: 2022-02-01 20:47:51.118 +0000 WET
  rules: [
    0: aws.backup.plan.rule ruleName="aws/efs/automatic-backup-rule" targetBackupVaultName="aws/efs/automatic-backup-vault"
  ]
}
aws.vpcs.first.routeTables.first.routes: [
  0: {
    CarrierGatewayId: null
    CoreNetworkArn: null
    DestinationCidrBlock: "172.31.0.0/16"
    DestinationIpv6CidrBlock: null
    DestinationPrefixListId: null
    EgressOnlyInternetGatewayId: null
    GatewayId: "local"
    InstanceId: null
    InstanceOwnerId: null
    IpAddress: null
    LocalGatewayId: null
    NatGatewayId: null
    NetworkInterfaceId: null
    OdbNetworkArn: null
    Origin: "CreateRouteTable"
    State: "active"
    TransitGatewayId: null
    VpcPeeringConnectionId: null
  }
  1: {
    CarrierGatewayId: null
    CoreNetworkArn: null
    DestinationCidrBlock: "0.0.0.0/0"
    DestinationIpv6CidrBlock: null
    DestinationPrefixListId: null
    EgressOnlyInternetGatewayId: null
    GatewayId: "igw-1234"
    InstanceId: null
    InstanceOwnerId: null
    IpAddress: null
    LocalGatewayId: null
    NatGatewayId: null
    NetworkInterfaceId: null
    OdbNetworkArn: null
    Origin: "CreateRoute"
    State: "active"
    TransitGatewayId: null
    VpcPeeringConnectionId: null
  }
]
aws.s3.buckets.first.encryptionRules: [
  0: {
    id: "arn:aws:s3:::foo/encryption/0"
    kmsMasterKeyId: ""
    bucketKeyEnabled: true
    sseAlgorithm: "AES256"
  }
]
> aws.ec2.instances.first{bootMode sourceDestCheck ipv6Address}
aws.ec2.instances.first: {
  sourceDestCheck: true
  bootMode: "uefi-preferred"
  ipv6Address: null
}
> aws.rds.instances.first{maxAllocatedStorage dedicatedLogVolume storageThroughput}
aws.rds.instances.first: {
  storageThroughput: 0
  dedicatedLogVolume: false
  maxAllocatedStorage: 1000
}
aws.iam.roles.first.path: "/"
aws.ecr.privateRepositories: [
  0: {
    name: "mondoo-samples"
    lifecyclePolicy: {
      rules: [
        0: {
          countType: "imageCountMoreThan"
          countNumber: 30
          tagStatus: "tagged"
          description: "Keep last 30 images"
          actionType: "expire"
          rulePriority: 1
        }
      ]
      lastEvaluatedAt: 2026-02-26 14:23:34.252 +0000 WET
    }
  }
]

@github-actions

This comment has been minimized.

@github-actions
Copy link
Copy Markdown
Contributor

github-actions bot commented Feb 23, 2026

Test Results

5 137 tests  ±0   5 133 ✅ ±0   2m 15s ⏱️ +18s
  409 suites ±0       4 💤 ±0 
   31 files   ±0       0 ❌ ±0 

Results for commit 3a04d29. ± Comparison against base commit 779ff93.

♻️ This comment has been updated with latest results.

@github-actions

This comment has been minimized.

@tas50 tas50 force-pushed the tas50/new_aws branch 2 times, most recently from 578b97d to 9437e39 Compare February 23, 2026 11:46
@tas50 tas50 changed the title ⭐ Expand AWS provider with new fields / resources ⭐ Add 6 new typed resources and ~50 fields across 20 AWS services Feb 23, 2026
Copy link
Copy Markdown

@mondoo-code-review mondoo-code-review bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Solid expansion of AWS provider resources; minor consistency issue with pointer handling

@github-actions

This comment has been minimized.

@mondoo-code-review mondoo-code-review bot dismissed their stale review February 23, 2026 11:48

Superseded by new review

Copy link
Copy Markdown

@mondoo-code-review mondoo-code-review bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Substantial expansion of AWS provider with new typed resources and fields. Code follows existing patterns but has minor pagination and style issues.

Copy link
Copy Markdown

@mondoo-code-review mondoo-code-review bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Solid additions, but critical bug in target group attributes and missing pagination

@mondoo-code-review mondoo-code-review bot dismissed their stale review February 23, 2026 11:59

Superseded by new review

Copy link
Copy Markdown

@mondoo-code-review mondoo-code-review bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Well-implemented addition of typed resources and fields. Minor improvements possible but no blocking issues.

@tas50 tas50 changed the title ⭐ Add 6 new typed resources and ~50 fields across 20 AWS services ⭐ Add 15 new typed resources and ~50 fields across 23 AWS services Feb 23, 2026
@github-actions

This comment has been minimized.

Copy link
Copy Markdown

@mondoo-code-review mondoo-code-review bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Two issues found: undefined function usage and inefficient redundant API call in encryptionKey()

@tas50 tas50 force-pushed the tas50/new_aws branch 2 times, most recently from 339d214 to 2d43a10 Compare February 23, 2026 15:27
Copy link
Copy Markdown

@mondoo-code-review mondoo-code-review bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Solid resource additions with one efficiency issue in CodeBuild and a type inconsistency in SageMaker

Copy link
Copy Markdown

@mondoo-code-review mondoo-code-review bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Solid resource additions with one efficiency issue: redundant API call in CodeBuild encryption key method

Copy link
Copy Markdown

@mondoo-code-review mondoo-code-review bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

IntDataDefault function may not exist; unusual pattern in init function needs verification

@tas50 tas50 force-pushed the tas50/new_aws branch 4 times, most recently from 49e77f3 to 094a7c0 Compare February 24, 2026 07:32
Copy link
Copy Markdown

@mondoo-code-review mondoo-code-review bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Schema additions look comprehensive, but found style guide violations for two-state enums and a non-standard init pattern

Copy link
Copy Markdown

@mondoo-code-review mondoo-code-review bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Well-structured PR with comprehensive resource additions, but CodeBuild timeout defaults need correction

Additional findings (file/line not in diff):

  • 🔵 providers/aws/resources/aws.lr:1057 — Changed IAM instance profile display defaults from arn instanceProfileId to instanceProfileId instanceProfileName. While more user-friendly, this changes existing behavior. Consider noting in changelog.

args["privilegedMode"] = llx.BoolData(*project.Environment.PrivilegedMode)
} else {
args["privilegedMode"] = llx.BoolData(false)
}
Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🔴 critical — Using 0 as default for timeoutInMinutes is incorrect. AWS CodeBuild default is 60 minutes. Use llx.IntDataDefault(project.TimeoutInMinutes, 60) or handle nil explicitly. Similarly, queuedTimeoutInMinutes defaults to 480 (8 hours), not 0.

kmsKey() aws.kms.key
// Whether SageMaker provides internet access to the instance
directInternetAccess string
directInternetAccess bool
Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🟡 warning — Changing directInternetAccess from string to bool is a breaking change. Ensure this is documented in release notes and that the implementation correctly maps SDK string values ("Enabled"/"Disabled") to bool.

@mondoo-code-review mondoo-code-review bot dismissed their stale review February 24, 2026 08:07

Superseded by new review

Copy link
Copy Markdown

@mondoo-code-review mondoo-code-review bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Well-structured implementation with proper nil handling, pagination, and lazy-loading patterns

@mondoo-code-review
Copy link
Copy Markdown

Unable to complete the code review. Please try again or reduce the PR size.

@tas50 tas50 changed the title ⭐ Add 15 new typed resources and ~50 fields across 23 AWS services ⭐ AWS: 18 new resources, ~70 new fields on existing resources, 23 services Feb 26, 2026
Copy link
Copy Markdown

@mondoo-code-review mondoo-code-review bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Well-structured additions with comprehensive resource definitions; two breaking changes need attention

Additional findings (file/line not in diff):

  • 🟡 providers/aws/resources/aws.lr:1306Breaking change: directInternetAccess changed from string to bool. AWS SDK returns "Enabled"/"Disabled" strings, so the implementation must convert these. This will break existing queries expecting a string value. Confirm this is intentional for v13 and ensure the implementation handles the conversion.

dataRepositoryAssociations []dict
// Resource tags
tags map[string]string
// Region where the cache exists
Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🟡 warningBreaking change: The tags field was removed from aws.fsx.cache. This will break existing queries using cache.tags. Verify this removal is intentional and document in the PR if this is part of v13 breaking changes.

Comment on lines +188 to +190
"agentVersion": llx.StringDataPtr(instance.AgentVersion),
"lastPingedAt": llx.TimeDataPtr(instance.LastPingDateTime),
"computerName": llx.StringDataPtr(instance.ComputerName),
Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🔵 suggestion — Implementation looks correct using llx.*DataPtr helpers for nil-safe pointer handling. Verify these fields exist in the AWS SDK's InstanceInformation type to avoid runtime panics.

Mondoo and others added 5 commits February 27, 2026 18:00
New typed resources:
- aws.fsx.volume: FSx ONTAP and OpenZFS volumes with flattened config fields
- aws.ec2.transitgateway: Transit gateways with flattened Options fields
- aws.neptune.snapshot: Neptune DB cluster snapshots (per-cluster)
- aws.redshift.snapshot: Redshift cluster snapshots (per-cluster)
- aws.backup.plan: Backup plans with lazy-loaded rules
- aws.backup.plan.rule: Backup plan rules with schedule, lifecycle, copy actions
- aws.backup.plan.rule.copyAction: Cross-region/account backup copies
- aws.backup.plan.advancedBackupSetting: Resource-specific backup options
- aws.backup.lifecycle: Typed lifecycle settings (cold storage, deletion)
- aws.elb.listener: ALB/NLB listeners with protocol, port, SSL policy
- aws.elb.loadbalancer.attribute: Typed LB attributes (deletion protection, access logs, etc.)
- aws.elb.targetgroup.attributes: Typed TG attributes (stickiness, algorithm, etc.)
- aws.vpc.routetable.route: Typed VPC route table entries
- aws.s3.bucket.encryptionRule: Typed S3 encryption rules
- aws.s3.bucket.replicationRule: Typed S3 replication rules

New fields on existing resources:
- EC2: bootMode, sourceDestCheck, ipv6Address on instances; description on images
- ECS: enableExecuteCommand, schedulingStrategy, platformFamily, cpu/memory on tasks
- ELB: ipAddressType, listeners(), instances(), typed attributes on load balancers
- RDS: licenseModel, maxAllocatedStorage, dedicatedLogVolume, storageThroughput,
  engineMode, earliestRestorableTime on clusters
- IAM: path on users, roles, and groups
- S3: typed encryptionRules() and replicationRules() on buckets
- Lambda: state, codeSize, stateReason, lastUpdateStatus
- CloudWatch: actionsEnabled on alarms; dataProtectionStatus, deletionProtection on log groups
- CodeBuild: createdAt, modifiedAt, privilegedMode, encryptionKey, timeouts
- ElastiCache: preferredMaintenanceWindow; subnets on serverless caches
- SageMaker: rootAccess, minimumInstanceMetadataServiceVersion, subnet
- SNS: kmsMasterKey on topics
- SQS: deduplicationScope, fifoThroughputLimit on queues
- SSM: agentVersion, lastPingedAt, computerName on instances
- Redshift: clusterAvailabilityStatus, multiAZ, ipAddressType, snapshots()
- ACM: renewalEligible, signatureAlgorithm on certificates
- CloudFront: comment on distributions
- DynamoDB: latestStreamLabel on tables
- ECR: lifecyclePolicy, scanningFrequency on repositories
- Neptune: snapshots() on clusters
- FSx: volumes() on service
- Backup: plans() on service

Signed-off-by: Tim Smith <tsmith84@gmail.com>
SageMaker directInternetAccess/rootAccess and transit gateway
autoAcceptSharedAttachments/defaultRouteTableAssociation/
defaultRouteTablePropagation/dnsSupport/multicastSupport/
vpnEcmpSupport are all two-state enums that map naturally to bool.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
TimeoutInMinutes defaults to 60 and QueuedTimeoutInMinutes to 480,
matching the actual AWS CodeBuild defaults.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
…S provider

- Add explicit __id to transit gateway, ELB listener, ELB attributes, FSx cache/backup
- Convert Redshift multiAZ from string to bool (missed in enum→bool conversion)
- Add region field to aws.fsx.cache and aws.fsx.backup for multi-region queries
- Remove fake tags field from aws.fsx.cache (SDK has no Tags on FileCache)
- Eliminate duplicate S3 GetBucketReplication/GetBucketEncryption calls via sync.Once caching
- Eliminate triplicate SNS GetTopicAttributes calls via fetchTopicAttributes helper
- Replace fragile string matching with typed LifecyclePolicyNotFoundException in ECR

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
Replace the untyped dict with two new resources (aws.ecr.lifecyclePolicy
and aws.ecr.lifecyclePolicy.rule) for type-safe MQL traversal. Also
exposes lastEvaluatedAt from the SDK response, which was previously
inaccessible.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
Copy link
Copy Markdown

@mondoo-code-review mondoo-code-review bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

These compile errors are pre-existing and unrelated to the PR under review. The PR only touches providers/aws/... files, while the failing tests live in:

  • providers/coordinator_test.go
  • providers/runtime_test.go
  • providers/os/connection/device/linux/device_manager_test.go

The root cause is that generated mock files are missing. The go:generate directives exist but the output files were never committed:

providers/coordinator.go declares:

//go:generate mockgen -source=./coordinator.go -destination=./mock_coordinator.go -package=providers
//go:generate mockgen -source=../providers-sdk/v1/plugin/interface.go -destination=./mock_plugin_interface.go -package=providers
//go:generate mockgen -source=../providers-sdk/v1/resources/schema.go -destination=./mock_schema.go -package=providers

providers/os/connection/snapshot/volumemounter.go declares:

//go:generate mockgen -source=./volumemounter.go -destination=./mock_volumemounter.go -package=snapshot

The generated files (mock_coordinator.go, mock_plugin_interface.go, mock_schema.go, mock_volumemounter.go) are absent from the repository. Running the following will fix it:

cd providers && go generate ./coordinator.go
cd providers/os/connection/snapshot && go generate ./volumemounter.go

Or from the repo root:

make mql/generate

Then commit the generated mock files. This issue exists independent of the current PR and should be addressed separately (or as a prerequisite before the next make test/go/plain run).

@syrull syrull merged commit 9b8a30c into main Feb 28, 2026
22 checks passed
@syrull syrull deleted the tas50/new_aws branch February 28, 2026 08:48
@github-actions github-actions bot locked and limited conversation to collaborators Feb 28, 2026
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants