import * as pulumi from "@pulumi/pulumi";
/**
 * Manages a single Secuirity Group Rule within the Yandex.Cloud. For more information, see the official documentation
 * of [security groups](https://cloud.yandex.com/docs/vpc/concepts/security-groups)
 * and [security group rules](https://cloud.yandex.com/docs/vpc/concepts/security-groups#rules).
 *
 * > **NOTE:** There is another way to manage security group rules by `ingress` and `egress` arguments in yandex_vpc_security_group. Both ways are equivalent but not compatible now. Using in-line rules of yandex.VpcSecurityGroup with Security Group Rule resource at the same time will cause a conflict of rules configuration.
 *
 * ## Example Usage
 *
 * ```typescript
 * import * as pulumi from "@pulumi/pulumi";
 * import * as yandex from "@pulumi/yandex";
 *
 * const lab_net = new yandex.VpcNetwork("lab-net", {});
 * const group1 = new yandex.VpcSecurityGroup("group1", {
 *     description: "description for my security group",
 *     networkId: lab_net.id,
 *     labels: {
 *         "my-label": "my-label-value",
 *     },
 * });
 * const rule1 = new yandex.VpcSecurityGroupRule("rule1", {
 *     securityGroupBinding: group1.id,
 *     direction: "ingress",
 *     description: "rule1 description",
 *     v4CidrBlocks: [
 *         "10.0.1.0/24",
 *         "10.0.2.0/24",
 *     ],
 *     port: 8080,
 *     protocol: "TCP",
 * });
 * const rule2 = new yandex.VpcSecurityGroupRule("rule2", {
 *     securityGroupBinding: group1.id,
 *     direction: "egress",
 *     description: "rule2 description",
 *     v4CidrBlocks: ["10.0.1.0/24"],
 *     fromPort: 8090,
 *     toPort: 8099,
 *     protocol: "UDP",
 * });
 * ```
 */
export declare class VpcSecurityGroupRule extends pulumi.CustomResource {
    /**
     * Get an existing VpcSecurityGroupRule resource's state with the given name, ID, and optional extra
     * properties used to qualify the lookup.
     *
     * @param name The _unique_ name of the resulting resource.
     * @param id The _unique_ provider ID of the resource to lookup.
     * @param state Any extra arguments used during the lookup.
     * @param opts Optional settings to control the behavior of the CustomResource.
     */
    static get(name: string, id: pulumi.Input<pulumi.ID>, state?: VpcSecurityGroupRuleState, opts?: pulumi.CustomResourceOptions): VpcSecurityGroupRule;
    /**
     * Returns true if the given object is an instance of VpcSecurityGroupRule.  This is designed to work even
     * when multiple copies of the Pulumi SDK have been loaded into the same process.
     */
    static isInstance(obj: any): obj is VpcSecurityGroupRule;
    /**
     * Description of the rule.
     */
    readonly description: pulumi.Output<string | undefined>;
    /**
     * direction of the rule. Can be `ingress` (inbound) or `egress` (outbound).
     */
    readonly direction: pulumi.Output<string>;
    /**
     * Minimum port number.
     */
    readonly fromPort: pulumi.Output<number | undefined>;
    /**
     * Labels to assign to this rule.
     */
    readonly labels: pulumi.Output<{
        [key: string]: string;
    }>;
    /**
     * Port number (if applied to a single port).
     */
    readonly port: pulumi.Output<number | undefined>;
    /**
     * Special-purpose targets such as "selfSecurityGroup". [See docs](https://cloud.yandex.com/docs/vpc/concepts/security-groups) for possible options.
     */
    readonly predefinedTarget: pulumi.Output<string | undefined>;
    /**
     * One of `ANY`, `TCP`, `UDP`, `ICMP`, `IPV6_ICMP`.
     */
    readonly protocol: pulumi.Output<string | undefined>;
    /**
     * ID of the security group this rule belongs to.
     */
    readonly securityGroupBinding: pulumi.Output<string>;
    /**
     * Target security group ID for this rule.
     */
    readonly securityGroupId: pulumi.Output<string | undefined>;
    /**
     * Maximum port number.
     */
    readonly toPort: pulumi.Output<number | undefined>;
    /**
     * The blocks of IPv4 addresses for this rule.
     */
    readonly v4CidrBlocks: pulumi.Output<string[] | undefined>;
    /**
     * The blocks of IPv6 addresses for this rule. `v6CidrBlocks` argument is currently not supported. It will be available in the future.
     */
    readonly v6CidrBlocks: pulumi.Output<string[] | undefined>;
    /**
     * Create a VpcSecurityGroupRule resource with the given unique name, arguments, and options.
     *
     * @param name The _unique_ name of the resource.
     * @param args The arguments to use to populate this resource's properties.
     * @param opts A bag of options that control this resource's behavior.
     */
    constructor(name: string, args: VpcSecurityGroupRuleArgs, opts?: pulumi.CustomResourceOptions);
}
/**
 * Input properties used for looking up and filtering VpcSecurityGroupRule resources.
 */
export interface VpcSecurityGroupRuleState {
    /**
     * Description of the rule.
     */
    description?: pulumi.Input<string>;
    /**
     * direction of the rule. Can be `ingress` (inbound) or `egress` (outbound).
     */
    direction?: pulumi.Input<string>;
    /**
     * Minimum port number.
     */
    fromPort?: pulumi.Input<number>;
    /**
     * Labels to assign to this rule.
     */
    labels?: pulumi.Input<{
        [key: string]: pulumi.Input<string>;
    }>;
    /**
     * Port number (if applied to a single port).
     */
    port?: pulumi.Input<number>;
    /**
     * Special-purpose targets such as "selfSecurityGroup". [See docs](https://cloud.yandex.com/docs/vpc/concepts/security-groups) for possible options.
     */
    predefinedTarget?: pulumi.Input<string>;
    /**
     * One of `ANY`, `TCP`, `UDP`, `ICMP`, `IPV6_ICMP`.
     */
    protocol?: pulumi.Input<string>;
    /**
     * ID of the security group this rule belongs to.
     */
    securityGroupBinding?: pulumi.Input<string>;
    /**
     * Target security group ID for this rule.
     */
    securityGroupId?: pulumi.Input<string>;
    /**
     * Maximum port number.
     */
    toPort?: pulumi.Input<number>;
    /**
     * The blocks of IPv4 addresses for this rule.
     */
    v4CidrBlocks?: pulumi.Input<pulumi.Input<string>[]>;
    /**
     * The blocks of IPv6 addresses for this rule. `v6CidrBlocks` argument is currently not supported. It will be available in the future.
     */
    v6CidrBlocks?: pulumi.Input<pulumi.Input<string>[]>;
}
/**
 * The set of arguments for constructing a VpcSecurityGroupRule resource.
 */
export interface VpcSecurityGroupRuleArgs {
    /**
     * Description of the rule.
     */
    description?: pulumi.Input<string>;
    /**
     * direction of the rule. Can be `ingress` (inbound) or `egress` (outbound).
     */
    direction: pulumi.Input<string>;
    /**
     * Minimum port number.
     */
    fromPort?: pulumi.Input<number>;
    /**
     * Labels to assign to this rule.
     */
    labels?: pulumi.Input<{
        [key: string]: pulumi.Input<string>;
    }>;
    /**
     * Port number (if applied to a single port).
     */
    port?: pulumi.Input<number>;
    /**
     * Special-purpose targets such as "selfSecurityGroup". [See docs](https://cloud.yandex.com/docs/vpc/concepts/security-groups) for possible options.
     */
    predefinedTarget?: pulumi.Input<string>;
    /**
     * One of `ANY`, `TCP`, `UDP`, `ICMP`, `IPV6_ICMP`.
     */
    protocol?: pulumi.Input<string>;
    /**
     * ID of the security group this rule belongs to.
     */
    securityGroupBinding: pulumi.Input<string>;
    /**
     * Target security group ID for this rule.
     */
    securityGroupId?: pulumi.Input<string>;
    /**
     * Maximum port number.
     */
    toPort?: pulumi.Input<number>;
    /**
     * The blocks of IPv4 addresses for this rule.
     */
    v4CidrBlocks?: pulumi.Input<pulumi.Input<string>[]>;
    /**
     * The blocks of IPv6 addresses for this rule. `v6CidrBlocks` argument is currently not supported. It will be available in the future.
     */
    v6CidrBlocks?: pulumi.Input<pulumi.Input<string>[]>;
}
