Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fortiwizard - New-AddressObject - Accept multiple entries #138

Closed
TheTaylorLee opened this issue Jul 5, 2023 · 0 comments · Fixed by #140
Closed

Fortiwizard - New-AddressObject - Accept multiple entries #138

TheTaylorLee opened this issue Jul 5, 2023 · 0 comments · Fixed by #140
Assignees
Labels

Comments

@TheTaylorLee
Copy link
Owner

Feature Target Details

  • Module Name: Fortiwizard
  • Existing Function Name: New-AddressObject

Describe the solution you'd like
Add the option to accept multiple cidrs and create multiple objects. Also consider a parameter to prepend the object names with a custom prefix.

Code Sample

  • Convert this from the tunnel functions to instead be used in this function.
#Create Remote Address Objects
[int]$max = $RemoteAddressCIDRs.Count
$script:RemoteAddressObjects = for ($i = 0; $i -lt $max; $i++) {
    [PSCustomObject]@{
        Name = "VPN_" + $TunnelName + "_Remote_" + $i
        CIDR = $RemoteAddressCIDRs[$i]
    }
}
@TheTaylorLee TheTaylorLee added the enhancement New feature or request label Jul 5, 2023
@TheTaylorLee TheTaylorLee self-assigned this Jul 6, 2023
@TheTaylorLee TheTaylorLee linked a pull request Jul 6, 2023 that will close this issue
4 tasks
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant