## Summary - Adds the Spec 431 Exchange PowerShell invocation gate and operation registration slice. - Introduces trusted provider operation start handling and read-only Exchange PowerShell runner abstractions. - Updates provider capability/readiness evaluation and coverage for Exchange PowerShell invocation safety. ## Verification - `cd apps/platform && ./vendor/bin/sail artisan test tests/Feature/Providers/ProviderCapabilityEvaluationTest.php tests/Feature/Providers/ProviderOperationCapabilityGateTest.php tests/Feature/TenantConfiguration/Spec431ExchangePowerShellInvocationGateTest.php tests/Unit/Providers/ProviderCapabilityRegistryTest.php tests/Unit/Providers/ProviderOperationStartGateTest.php tests/Unit/Support/TenantConfiguration/Spec430ExchangePowerShellCommandAllowlistTest.php tests/Unit/Support/TenantConfiguration/Spec431ExchangePowerShellOperationRegistrationTest.php tests/Unit/Verification/ManagedEnvironmentPermissionCapabilityMappingTest.php` - Result: 80 passed, 685 assertions. ## Product Surface / Ops - Rendered UI surface changed: N/A. - Filament/Livewire surface changed: N/A. - Deployment impact: config/runtime service changes only; no migrations, queues, or assets added. Co-authored-by: Ahmed Darrazi <ahmed.darrazi@live.de> Reviewed-on: #498
41 lines
1.3 KiB
PHP
41 lines
1.3 KiB
PHP
<?php
|
|
|
|
declare(strict_types=1);
|
|
|
|
namespace App\Services\TenantConfiguration;
|
|
|
|
final readonly class ExchangePowerShellInvocationContext
|
|
{
|
|
public function __construct(
|
|
public int $operationRunId,
|
|
public int $workspaceId,
|
|
public int $managedEnvironmentId,
|
|
public int $providerConnectionId,
|
|
public string $canonicalType,
|
|
public string $commandName,
|
|
public string $runnerMode,
|
|
public string $redactionPolicy,
|
|
public string $sourceContractState,
|
|
public ?string $credentialSource = null,
|
|
) {}
|
|
|
|
/**
|
|
* @return array<string, mixed>
|
|
*/
|
|
public function toArray(): array
|
|
{
|
|
return array_filter([
|
|
'operation_run_id' => $this->operationRunId,
|
|
'workspace_id' => $this->workspaceId,
|
|
'managed_environment_id' => $this->managedEnvironmentId,
|
|
'provider_connection_id' => $this->providerConnectionId,
|
|
'canonical_type' => $this->canonicalType,
|
|
'command_name' => $this->commandName,
|
|
'runner_mode' => $this->runnerMode,
|
|
'redaction_policy' => $this->redactionPolicy,
|
|
'source_contract_state' => $this->sourceContractState,
|
|
'credential_source' => $this->credentialSource,
|
|
], static fn (mixed $value): bool => $value !== null && $value !== '');
|
|
}
|
|
}
|