Open johan-kummeneje-complior opened 1 month ago
When using the Get-FGTMonitorSystemConfigBackup command with -vdom vdomX it will return the full config.
This is easily fixed as the scope just needs to be changed from global to vdom if vdom is given on commandline.
$scope=global if ( $PsBoundParameters.ContainsKey('vdom') ) { $invokeParams.add( 'vdom', $vdom ) $scope="vdom" }
if ($connection.version -lt "7.6.0") { $method = "get" $uri = 'api/v2/monitor/system/config/backup?scope=$scope' $body = "" } else { $method = "post" $uri = 'api/v2/monitor/system/config/backup' $body = @{ "scope" = "$scope" } }
Hi @johan-kummeneje-complior
thanks for the report ! Can you push a PR with the fix ?
Pull request https://github.com/FortiPower/PowerFGT/pull/272 is created.
When using the Get-FGTMonitorSystemConfigBackup command with -vdom vdomX it will return the full config.
This is easily fixed as the scope just needs to be changed from global to vdom if vdom is given on commandline.
$scope=global if ( $PsBoundParameters.ContainsKey('vdom') ) { $invokeParams.add( 'vdom', $vdom ) $scope="vdom" }
before 7.6.x, config/backup is available with get method and using paramater