# boolean_smtp_aws_enable_imds_role_source

> Filters whether BooleanSMTP probes the EC2 IMDSv2 endpoint for an IAM role.

Filter · Tier B · Since 1.0.0



## Signature

```php
add_filter( 'boolean_smtp_aws_enable_imds_role_source', $callback, 10, 1 );
```

## Parameters

| Name | Type | Description |
| --- | --- | --- |
| `$enabled` | `bool` | Whether the probe is currently enabled by constant or environment variable. Return true to enable it. |

**Returns** `bool` — The filtered value.

## Fires in

- [app/Services/Settings/CredentialSourceDetector.php:324](https://github.com/booleanpress/boolean-smtp-src/blob/main/app/Services/Settings/CredentialSourceDetector.php#L324) — `BooleanSmtp\Services\Settings\CredentialSourceDetector::shouldProbeIamRole()`

## Example

```php
add_filter( 'boolean_smtp_aws_enable_imds_role_source', function ( bool $enabled ) {
    return $enabled;
}, 10, 1 );
```
