Strata Cloud Manager v0.4.3 published on Saturday, Nov 8, 2025 by Pulumi
Strata Cloud Manager v0.4.3 published on Saturday, Nov 8, 2025 by Pulumi
PbfRule data source
Example Usage
import * as pulumi from "@pulumi/pulumi";
import * as scm from "@pulumi/scm";
const exampleTag = new scm.Tag("example_tag", {
folder: "All",
name: "pbf-rule-tag-ds-test-1",
color: "Red",
});
// --- PBF Rule Resource with discard action---
const examplePbfRule = new scm.PbfRule("example_pbf_rule", {
name: "pbf-test-ds-rule-discard",
folder: "All",
description: "Data Source testing pbf rule.",
from: {
zones: ["zone-untrust"],
},
sources: ["any"],
destinations: ["any"],
applications: ["any"],
services: ["service-http"],
sourceUsers: ["any"],
action: {
discard: {},
},
tags: [exampleTag.name],
enforceSymmetricReturn: {
enabled: false,
},
schedule: "non-work-hours",
});
// Define the data source (the item to be retrieved via API GET)
const pbfExternalWebTestGet = scm.getPbfRuleOutput({
id: examplePbfRule.id,
});
export const retrievedIDAndName = {
id: pbfExternalWebTestGet.apply(pbfExternalWebTestGet => pbfExternalWebTestGet.id),
name: pbfExternalWebTestGet.apply(pbfExternalWebTestGet => pbfExternalWebTestGet.name),
};
export const recievedResponse = pbfExternalWebTestGet;
import pulumi
import pulumi_scm as scm
example_tag = scm.Tag("example_tag",
folder="All",
name="pbf-rule-tag-ds-test-1",
color="Red")
# --- PBF Rule Resource with discard action---
example_pbf_rule = scm.PbfRule("example_pbf_rule",
name="pbf-test-ds-rule-discard",
folder="All",
description="Data Source testing pbf rule.",
from_={
"zones": ["zone-untrust"],
},
sources=["any"],
destinations=["any"],
applications=["any"],
services=["service-http"],
source_users=["any"],
action={
"discard": {},
},
tags=[example_tag.name],
enforce_symmetric_return={
"enabled": False,
},
schedule="non-work-hours")
# Define the data source (the item to be retrieved via API GET)
pbf_external_web_test_get = scm.get_pbf_rule_output(id=example_pbf_rule.id)
pulumi.export("retrievedIDAndName", {
"id": pbf_external_web_test_get.id,
"name": pbf_external_web_test_get.name,
})
pulumi.export("recievedResponse", pbf_external_web_test_get)
package main
import (
"github.com/pulumi/pulumi-scm/sdk/go/scm"
"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
)
func main() {
pulumi.Run(func(ctx *pulumi.Context) error {
exampleTag, err := scm.NewTag(ctx, "example_tag", &scm.TagArgs{
Folder: pulumi.String("All"),
Name: pulumi.String("pbf-rule-tag-ds-test-1"),
Color: pulumi.String("Red"),
})
if err != nil {
return err
}
// --- PBF Rule Resource with discard action---
examplePbfRule, err := scm.NewPbfRule(ctx, "example_pbf_rule", &scm.PbfRuleArgs{
Name: pulumi.String("pbf-test-ds-rule-discard"),
Folder: pulumi.String("All"),
Description: pulumi.String("Data Source testing pbf rule."),
From: &scm.PbfRuleFromArgs{
Zones: pulumi.StringArray{
pulumi.String("zone-untrust"),
},
},
Sources: pulumi.StringArray{
pulumi.String("any"),
},
Destinations: pulumi.StringArray{
pulumi.String("any"),
},
Applications: pulumi.StringArray{
pulumi.String("any"),
},
Services: pulumi.StringArray{
pulumi.String("service-http"),
},
SourceUsers: pulumi.StringArray{
pulumi.String("any"),
},
Action: &scm.PbfRuleActionArgs{
Discard: &scm.PbfRuleActionDiscardArgs{},
},
Tags: pulumi.StringArray{
exampleTag.Name,
},
EnforceSymmetricReturn: &scm.PbfRuleEnforceSymmetricReturnArgs{
Enabled: pulumi.Bool(false),
},
Schedule: pulumi.String("non-work-hours"),
})
if err != nil {
return err
}
// Define the data source (the item to be retrieved via API GET)
pbfExternalWebTestGet := scm.LookupPbfRuleOutput(ctx, scm.GetPbfRuleOutputArgs{
Id: examplePbfRule.ID(),
}, nil)
ctx.Export("retrievedIDAndName", pulumi.StringMap{
"id": pbfExternalWebTestGet.ApplyT(func(pbfExternalWebTestGet scm.GetPbfRuleResult) (*string, error) {
return &pbfExternalWebTestGet.Id, nil
}).(pulumi.StringPtrOutput),
"name": pbfExternalWebTestGet.ApplyT(func(pbfExternalWebTestGet scm.GetPbfRuleResult) (*string, error) {
return &pbfExternalWebTestGet.Name, nil
}).(pulumi.StringPtrOutput),
})
ctx.Export("recievedResponse", pbfExternalWebTestGet)
return nil
})
}
using System.Collections.Generic;
using System.Linq;
using Pulumi;
using Scm = Pulumi.Scm;
return await Deployment.RunAsync(() =>
{
var exampleTag = new Scm.Tag("example_tag", new()
{
Folder = "All",
Name = "pbf-rule-tag-ds-test-1",
Color = "Red",
});
// --- PBF Rule Resource with discard action---
var examplePbfRule = new Scm.PbfRule("example_pbf_rule", new()
{
Name = "pbf-test-ds-rule-discard",
Folder = "All",
Description = "Data Source testing pbf rule.",
From = new Scm.Inputs.PbfRuleFromArgs
{
Zones = new[]
{
"zone-untrust",
},
},
Sources = new[]
{
"any",
},
Destinations = new[]
{
"any",
},
Applications = new[]
{
"any",
},
Services = new[]
{
"service-http",
},
SourceUsers = new[]
{
"any",
},
Action = new Scm.Inputs.PbfRuleActionArgs
{
Discard = null,
},
Tags = new[]
{
exampleTag.Name,
},
EnforceSymmetricReturn = new Scm.Inputs.PbfRuleEnforceSymmetricReturnArgs
{
Enabled = false,
},
Schedule = "non-work-hours",
});
// Define the data source (the item to be retrieved via API GET)
var pbfExternalWebTestGet = Scm.GetPbfRule.Invoke(new()
{
Id = examplePbfRule.Id,
});
return new Dictionary<string, object?>
{
["retrievedIDAndName"] =
{
{ "id", pbfExternalWebTestGet.Apply(getPbfRuleResult => getPbfRuleResult.Id) },
{ "name", pbfExternalWebTestGet.Apply(getPbfRuleResult => getPbfRuleResult.Name) },
},
["recievedResponse"] = pbfExternalWebTestGet,
};
});
package generated_program;
import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.scm.Tag;
import com.pulumi.scm.TagArgs;
import com.pulumi.scm.PbfRule;
import com.pulumi.scm.PbfRuleArgs;
import com.pulumi.scm.inputs.PbfRuleFromArgs;
import com.pulumi.scm.inputs.PbfRuleActionArgs;
import com.pulumi.scm.inputs.PbfRuleActionDiscardArgs;
import com.pulumi.scm.inputs.PbfRuleEnforceSymmetricReturnArgs;
import com.pulumi.scm.ScmFunctions;
import com.pulumi.scm.inputs.GetPbfRuleArgs;
import java.util.List;
import java.util.ArrayList;
import java.util.Map;
import java.io.File;
import java.nio.file.Files;
import java.nio.file.Paths;
public class App {
public static void main(String[] args) {
Pulumi.run(App::stack);
}
public static void stack(Context ctx) {
var exampleTag = new Tag("exampleTag", TagArgs.builder()
.folder("All")
.name("pbf-rule-tag-ds-test-1")
.color("Red")
.build());
// --- PBF Rule Resource with discard action---
var examplePbfRule = new PbfRule("examplePbfRule", PbfRuleArgs.builder()
.name("pbf-test-ds-rule-discard")
.folder("All")
.description("Data Source testing pbf rule.")
.from(PbfRuleFromArgs.builder()
.zones("zone-untrust")
.build())
.sources("any")
.destinations("any")
.applications("any")
.services("service-http")
.sourceUsers("any")
.action(PbfRuleActionArgs.builder()
.discard(PbfRuleActionDiscardArgs.builder()
.build())
.build())
.tags(exampleTag.name())
.enforceSymmetricReturn(PbfRuleEnforceSymmetricReturnArgs.builder()
.enabled(false)
.build())
.schedule("non-work-hours")
.build());
// Define the data source (the item to be retrieved via API GET)
final var pbfExternalWebTestGet = ScmFunctions.getPbfRule(GetPbfRuleArgs.builder()
.id(examplePbfRule.id())
.build());
ctx.export("retrievedIDAndName", Map.ofEntries(
Map.entry("id", pbfExternalWebTestGet.applyValue(_pbfExternalWebTestGet -> _pbfExternalWebTestGet.id())),
Map.entry("name", pbfExternalWebTestGet.applyValue(_pbfExternalWebTestGet -> _pbfExternalWebTestGet.name()))
));
ctx.export("recievedResponse", pbfExternalWebTestGet);
}
}
resources:
exampleTag:
type: scm:Tag
name: example_tag
properties:
folder: All
name: pbf-rule-tag-ds-test-1
color: Red
# --- PBF Rule Resource with discard action---
examplePbfRule:
type: scm:PbfRule
name: example_pbf_rule
properties:
name: pbf-test-ds-rule-discard
folder: All
description: Data Source testing pbf rule.
from:
zones:
- zone-untrust
sources: # Source addresses
- any
destinations: # Destination addresses
- any
applications: # Applications
- any
services: # Services (ports/protocols)
- service-http
sourceUsers:
- any
action:
discard: {}
tags:
- ${exampleTag.name}
enforceSymmetricReturn:
enabled: false
schedule: non-work-hours
variables:
# Define the data source (the item to be retrieved via API GET)
pbfExternalWebTestGet:
fn::invoke:
function: scm:getPbfRule
arguments:
id: ${examplePbfRule.id}
outputs:
# --- Output Blocks to Print Retrieved Data ---
retrievedIDAndName:
id: ${pbfExternalWebTestGet.id}
name: ${pbfExternalWebTestGet.name}
recievedResponse: ${pbfExternalWebTestGet}
Using getPbfRule
Two invocation forms are available. The direct form accepts plain arguments and either blocks until the result value is available, or returns a Promise-wrapped result. The output form accepts Input-wrapped arguments and returns an Output-wrapped result.
function getPbfRule(args: GetPbfRuleArgs, opts?: InvokeOptions): Promise<GetPbfRuleResult>
function getPbfRuleOutput(args: GetPbfRuleOutputArgs, opts?: InvokeOptions): Output<GetPbfRuleResult>def get_pbf_rule(id: Optional[str] = None,
name: Optional[str] = None,
opts: Optional[InvokeOptions] = None) -> GetPbfRuleResult
def get_pbf_rule_output(id: Optional[pulumi.Input[str]] = None,
name: Optional[pulumi.Input[str]] = None,
opts: Optional[InvokeOptions] = None) -> Output[GetPbfRuleResult]func LookupPbfRule(ctx *Context, args *LookupPbfRuleArgs, opts ...InvokeOption) (*LookupPbfRuleResult, error)
func LookupPbfRuleOutput(ctx *Context, args *LookupPbfRuleOutputArgs, opts ...InvokeOption) LookupPbfRuleResultOutput> Note: This function is named LookupPbfRule in the Go SDK.
public static class GetPbfRule
{
public static Task<GetPbfRuleResult> InvokeAsync(GetPbfRuleArgs args, InvokeOptions? opts = null)
public static Output<GetPbfRuleResult> Invoke(GetPbfRuleInvokeArgs args, InvokeOptions? opts = null)
}public static CompletableFuture<GetPbfRuleResult> getPbfRule(GetPbfRuleArgs args, InvokeOptions options)
public static Output<GetPbfRuleResult> getPbfRule(GetPbfRuleArgs args, InvokeOptions options)
fn::invoke:
function: scm:index/getPbfRule:getPbfRule
arguments:
# arguments dictionaryThe following arguments are supported:
getPbfRule Result
The following output properties are available:
- Action
Get
Pbf Rule Action - Action
- Applications List<string>
- Applications
- Description string
- Description
- Destinations List<string>
- Destination addresses
- Device string
- The device in which the resource is defined
- Enforce
Symmetric GetReturn Pbf Rule Enforce Symmetric Return - Enforce symmetric return
- Folder string
- The folder in which the resource is defined
- From
Get
Pbf Rule From - From
- Id string
- UUID of the resource
- Name string
- PBF rule name
- Schedule string
- Schedule
- Services List<string>
- Services
- Snippet string
- The snippet in which the resource is defined
- Source
Users List<string> - Source users
- Sources List<string>
- Source addresses
- List<string>
- Tags
- Tfid string
- Action
Get
Pbf Rule Action - Action
- Applications []string
- Applications
- Description string
- Description
- Destinations []string
- Destination addresses
- Device string
- The device in which the resource is defined
- Enforce
Symmetric GetReturn Pbf Rule Enforce Symmetric Return - Enforce symmetric return
- Folder string
- The folder in which the resource is defined
- From
Get
Pbf Rule From - From
- Id string
- UUID of the resource
- Name string
- PBF rule name
- Schedule string
- Schedule
- Services []string
- Services
- Snippet string
- The snippet in which the resource is defined
- Source
Users []string - Source users
- Sources []string
- Source addresses
- []string
- Tags
- Tfid string
- action
Get
Pbf Rule Action - Action
- applications List<String>
- Applications
- description String
- Description
- destinations List<String>
- Destination addresses
- device String
- The device in which the resource is defined
- enforce
Symmetric GetReturn Pbf Rule Enforce Symmetric Return - Enforce symmetric return
- folder String
- The folder in which the resource is defined
- from
Get
Pbf Rule From - From
- id String
- UUID of the resource
- name String
- PBF rule name
- schedule String
- Schedule
- services List<String>
- Services
- snippet String
- The snippet in which the resource is defined
- source
Users List<String> - Source users
- sources List<String>
- Source addresses
- List<String>
- Tags
- tfid String
- action
Get
Pbf Rule Action - Action
- applications string[]
- Applications
- description string
- Description
- destinations string[]
- Destination addresses
- device string
- The device in which the resource is defined
- enforce
Symmetric GetReturn Pbf Rule Enforce Symmetric Return - Enforce symmetric return
- folder string
- The folder in which the resource is defined
- from
Get
Pbf Rule From - From
- id string
- UUID of the resource
- name string
- PBF rule name
- schedule string
- Schedule
- services string[]
- Services
- snippet string
- The snippet in which the resource is defined
- source
Users string[] - Source users
- sources string[]
- Source addresses
- string[]
- Tags
- tfid string
- action
Get
Pbf Rule Action - Action
- applications Sequence[str]
- Applications
- description str
- Description
- destinations Sequence[str]
- Destination addresses
- device str
- The device in which the resource is defined
- enforce_
symmetric_ Getreturn Pbf Rule Enforce Symmetric Return - Enforce symmetric return
- folder str
- The folder in which the resource is defined
- from_
Get
Pbf Rule From - From
- id str
- UUID of the resource
- name str
- PBF rule name
- schedule str
- Schedule
- services Sequence[str]
- Services
- snippet str
- The snippet in which the resource is defined
- source_
users Sequence[str] - Source users
- sources Sequence[str]
- Source addresses
- Sequence[str]
- Tags
- tfid str
- action Property Map
- Action
- applications List<String>
- Applications
- description String
- Description
- destinations List<String>
- Destination addresses
- device String
- The device in which the resource is defined
- enforce
Symmetric Property MapReturn - Enforce symmetric return
- folder String
- The folder in which the resource is defined
- from Property Map
- From
- id String
- UUID of the resource
- name String
- PBF rule name
- schedule String
- Schedule
- services List<String>
- Services
- snippet String
- The snippet in which the resource is defined
- source
Users List<String> - Source users
- sources List<String>
- Source addresses
- List<String>
- Tags
- tfid String
Supporting Types
GetPbfRuleAction
- Discard
Get
Pbf Rule Action Discard - Discard
- Forward
Get
Pbf Rule Action Forward - Forward
- No
Pbf GetPbf Rule Action No Pbf - No pbf
- Discard
Get
Pbf Rule Action Discard - Discard
- Forward
Get
Pbf Rule Action Forward - Forward
- No
Pbf GetPbf Rule Action No Pbf - No pbf
- discard
Get
Pbf Rule Action Discard - Discard
- forward
Get
Pbf Rule Action Forward - Forward
- no
Pbf GetPbf Rule Action No Pbf - No pbf
- discard
Get
Pbf Rule Action Discard - Discard
- forward
Get
Pbf Rule Action Forward - Forward
- no
Pbf GetPbf Rule Action No Pbf - No pbf
- discard
Get
Pbf Rule Action Discard - Discard
- forward
Get
Pbf Rule Action Forward - Forward
- no_
pbf GetPbf Rule Action No Pbf - No pbf
- discard Property Map
- Discard
- forward Property Map
- Forward
- no
Pbf Property Map - No pbf
GetPbfRuleActionForward
- Egress
Interface string - Egress interface
- Monitor
Get
Pbf Rule Action Forward Monitor - Monitor
- Nexthop
Get
Pbf Rule Action Forward Nexthop - Nexthop
- Egress
Interface string - Egress interface
- Monitor
Get
Pbf Rule Action Forward Monitor - Monitor
- Nexthop
Get
Pbf Rule Action Forward Nexthop - Nexthop
- egress
Interface String - Egress interface
- monitor
Get
Pbf Rule Action Forward Monitor - Monitor
- nexthop
Get
Pbf Rule Action Forward Nexthop - Nexthop
- egress
Interface string - Egress interface
- monitor
Get
Pbf Rule Action Forward Monitor - Monitor
- nexthop
Get
Pbf Rule Action Forward Nexthop - Nexthop
- egress_
interface str - Egress interface
- monitor
Get
Pbf Rule Action Forward Monitor - Monitor
- nexthop
Get
Pbf Rule Action Forward Nexthop - Nexthop
- egress
Interface String - Egress interface
- monitor Property Map
- Monitor
- nexthop Property Map
- Nexthop
GetPbfRuleActionForwardMonitor
- Disable
If boolUnreachable - Disable this rule if nexthop/monitor ip is unreachable?
- Ip
Address string - Monitor IP address
- Profile string
- Monitoring profile
- Disable
If boolUnreachable - Disable this rule if nexthop/monitor ip is unreachable?
- Ip
Address string - Monitor IP address
- Profile string
- Monitoring profile
- disable
If BooleanUnreachable - Disable this rule if nexthop/monitor ip is unreachable?
- ip
Address String - Monitor IP address
- profile String
- Monitoring profile
- disable
If booleanUnreachable - Disable this rule if nexthop/monitor ip is unreachable?
- ip
Address string - Monitor IP address
- profile string
- Monitoring profile
- disable_
if_ boolunreachable - Disable this rule if nexthop/monitor ip is unreachable?
- ip_
address str - Monitor IP address
- profile str
- Monitoring profile
- disable
If BooleanUnreachable - Disable this rule if nexthop/monitor ip is unreachable?
- ip
Address String - Monitor IP address
- profile String
- Monitoring profile
GetPbfRuleActionForwardNexthop
- fqdn str
- Next hop FQDN
- ip_
address str - Next hop IP address
GetPbfRuleEnforceSymmetricReturn
- Enabled bool
- Enforce symmetric return?
- Nexthop
Address List<GetLists Pbf Rule Enforce Symmetric Return Nexthop Address List> - Next hop IP addresses
- Enabled bool
- Enforce symmetric return?
- Nexthop
Address []GetLists Pbf Rule Enforce Symmetric Return Nexthop Address List - Next hop IP addresses
- enabled Boolean
- Enforce symmetric return?
- nexthop
Address List<GetLists Pbf Rule Enforce Symmetric Return Nexthop Address List> - Next hop IP addresses
- enabled boolean
- Enforce symmetric return?
- nexthop
Address GetLists Pbf Rule Enforce Symmetric Return Nexthop Address List[] - Next hop IP addresses
- enabled bool
- Enforce symmetric return?
- nexthop_
address_ Sequence[Getlists Pbf Rule Enforce Symmetric Return Nexthop Address List] - Next hop IP addresses
- enabled Boolean
- Enforce symmetric return?
- nexthop
Address List<Property Map>Lists - Next hop IP addresses
GetPbfRuleEnforceSymmetricReturnNexthopAddressList
- Name string
- Next hop IP address
- Name string
- Next hop IP address
- name String
- Next hop IP address
- name string
- Next hop IP address
- name str
- Next hop IP address
- name String
- Next hop IP address
GetPbfRuleFrom
- Interfaces List<string>
- Source interfaces
- Zones List<string>
- Source zones
- Interfaces []string
- Source interfaces
- Zones []string
- Source zones
- interfaces List<String>
- Source interfaces
- zones List<String>
- Source zones
- interfaces string[]
- Source interfaces
- zones string[]
- Source zones
- interfaces Sequence[str]
- Source interfaces
- zones Sequence[str]
- Source zones
- interfaces List<String>
- Source interfaces
- zones List<String>
- Source zones
Package Details
- Repository
- scm pulumi/pulumi-scm
- License
- Apache-2.0
- Notes
- This Pulumi package is based on the
scmTerraform Provider.
Strata Cloud Manager v0.4.3 published on Saturday, Nov 8, 2025 by Pulumi
