<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic Re: Terraform NGFW provider failing to get token for CloudFirewallAdmin in Cloud NGFW for AWS Discussions</title>
    <link>https://live.paloaltonetworks.com/t5/cloud-ngfw-for-aws-discussions/terraform-ngfw-provider-failing-to-get-token-for/m-p/484590#M288</link>
    <description>&lt;DIV dir="ltr"&gt;Thanks &lt;span class="lia-unicode-emoji" title=":slightly_smiling_face:"&gt;🙂&lt;/span&gt;&lt;/DIV&gt;
&lt;DIV dir="ltr"&gt;I did get stuck on another thing though. The rulestack resource execution was followed by commit_rulestack resource. The default state is set to Running. However, when the NFGW resource was being created, I had a timeout after around 5 minutes and 30 seconds. When I ran tf plan once more, tf wanted to change state from “precommitdone” to “running” (due to default state in terraform resource block being “running” and state on Palo NGFW UI being “precommitdone”. I wasn’t able to run terraform apply again due to recurring error&amp;nbsp;&lt;/DIV&gt;
&lt;DIV dir="ltr"&gt;&amp;nbsp;&lt;/DIV&gt;
&lt;DIV dir="ltr"&gt;&lt;LI-CODE lang="markup"&gt;module.base.cloudngfwaws_commit_rulestack.commit-test-rulestack-terraform: Creating...
╷
│ Error: Error(1): Commit process unfinished.
│ 
│   with module.base.cloudngfwaws_commit_rulestack.commit-test-rulestack-terraform,
│   on modules/base/palo-ngfw.tf line 33, in resource "cloudngfwaws_commit_rulestack" "commit-test-rulestack-terraform":
│   33: resource "cloudngfwaws_commit_rulestack" "commit-test-rulestack-terraform" {&lt;/LI-CODE&gt;&lt;/DIV&gt;
&lt;DIV dir="ltr"&gt;&amp;nbsp;&lt;/DIV&gt;
&lt;DIV dir="ltr"&gt;I am also unable to delete the rulestack from NGFW UI.&lt;/DIV&gt;
&lt;DIV dir="ltr"&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="SZanpure_0-1651603551332.png" style="width: 999px;"&gt;&lt;img src="https://live.paloaltonetworks.com/t5/image/serverpage/image-id/40833i9D8C8178E65AC641/image-size/large/is-moderation-mode/true?v=v2&amp;amp;px=999" role="button" title="SZanpure_0-1651603551332.png" alt="SZanpure_0-1651603551332.png" /&gt;&lt;/span&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;/DIV&gt;
&lt;DIV dir="ltr"&gt;Have you encountered this? The docs suggest that I should look at the read-only properties on the rulestack to find it’s status, which can be done via output vars, but does mean that all ruelstacks need to be defined in their own module?&lt;/DIV&gt;
&lt;DIV dir="ltr"&gt;It would be great if the docs could include an example of some sort dependency, where NGFW is created only after rulestack has switched to a status of “Running” in Palo UI, instead of setting the default state in terraform which does not truly reflect the state in Palo UI. Hope that makes sense.&lt;/DIV&gt;
&lt;DIV dir="ltr"&gt;&amp;nbsp;&lt;/DIV&gt;
&lt;DIV dir="ltr"&gt;Thanks,&lt;/DIV&gt;
&lt;DIV dir="ltr"&gt;Shreyas&amp;nbsp;&lt;/DIV&gt;</description>
    <pubDate>Tue, 03 May 2022 18:46:07 GMT</pubDate>
    <dc:creator>SZanpure</dc:creator>
    <dc:date>2022-05-03T18:46:07Z</dc:date>
    <item>
      <title>Terraform NGFW provider failing to get token for CloudFirewallAdmin</title>
      <link>https://live.paloaltonetworks.com/t5/cloud-ngfw-for-aws-discussions/terraform-ngfw-provider-failing-to-get-token-for/m-p/483472#M276</link>
      <description>&lt;P&gt;Hi,&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;I am trialling out the TF provider in this&amp;nbsp;&lt;A href="https://github.com/PaloAltoNetworks/terraform-provider-cloudngfwaws" target="_self"&gt;repo&lt;/A&gt;&amp;nbsp;and I have successfully built the provider locally. I am able to configure it as per the settings mentioned in the doc. To give a brief overview, I have&lt;/P&gt;
&lt;OL&gt;
&lt;LI&gt;Subscribed to Palo NGFW in AWS Marketplace&lt;/LI&gt;
&lt;LI&gt;Added our sandbox AWS Account to Palo NGFW and run the Cloudformation template which creates cross-account IAM roles.&lt;/LI&gt;
&lt;LI&gt;Enabled Programmatic access and created the IAM role mentioned in the docs to grant access to API Gateway. I have also tagged the IAM role with&amp;nbsp;
&lt;P&gt;&lt;SPAN&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; Key=NGFWaasRole, Value=CloudFirewallAdmin&lt;/SPAN&gt;&lt;/P&gt;
&lt;P&gt;&lt;SPAN&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; Key=NGFWaasRole, Value=CloudRulestackAdmin&lt;/SPAN&gt;&lt;/P&gt;
tags as mentioned in the other&amp;nbsp;&lt;A href="https://live.paloaltonetworks.com/t5/cloud-ngfw-discussions/programmatic-access-for-cloud-ngfw/td-p/478170" target="_self"&gt;ticket&lt;/A&gt;&lt;/LI&gt;
&lt;LI&gt;&amp;nbsp;I have granted sts:AssumeRole permission so that any authenticated user in my sandbox account can assume the above role.&lt;/LI&gt;
&lt;LI&gt;After setting up all of this, I supply the following config values to the provider&lt;/LI&gt;
&lt;/OL&gt;
&lt;P&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;host:&amp;nbsp;&lt;SPAN&gt;"api.us-east-1.aws.cloudngfw.paloaltonetworks.com"&lt;/SPAN&gt;&lt;/P&gt;
&lt;P&gt;&lt;SPAN&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;region: "us-east-1"&lt;/SPAN&gt;&lt;/P&gt;
&lt;P&gt;&lt;SPAN&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;arn: "&amp;lt;The arn of the API Gateway IAM Role I setup in step 3&amp;gt;"&lt;/SPAN&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&lt;SPAN&gt;The provider initialises successfully when I run &lt;STRONG&gt;terraform init&lt;/STRONG&gt;&lt;/SPAN&gt;, however when I run &lt;STRONG&gt;terraform plan&lt;/STRONG&gt;, it errors as per the screenshot below&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="SZanpure_0-1651135413137.png" style="width: 999px;"&gt;&lt;img src="https://live.paloaltonetworks.com/t5/image/serverpage/image-id/40581i1F748C1797A39E53/image-size/large/is-moderation-mode/true?v=v2&amp;amp;px=999" role="button" title="SZanpure_0-1651135413137.png" alt="SZanpure_0-1651135413137.png" /&gt;&lt;/span&gt;&lt;/P&gt;
&lt;P&gt;I can only speculate (since I am not familiar with golang, but the code for ngfw client is&amp;nbsp;&lt;A href="https://github.com/PaloAltoNetworks/cloud-ngfw-aws-go/blob/main/client.go" target="_self"&gt;here&lt;/A&gt;&amp;nbsp;) that the client is failing to execute steps 8 and 9 mentioned&amp;nbsp;&lt;A href="https://docs.paloaltonetworks.com/cloud-ngfw/aws/cloud-ngfw-on-aws/getting-started-with-cloud-ngfw-for-aws/enable-programmatic-access" target="_self"&gt;here&lt;/A&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Another thing to note is that the tags mentioned in step 5 of the above article are different from the ones you have mentioned in the linked ticket above. Is there any reason for this difference? Also, the Github repo linked in step 6 has a broken link, so I cannot view the CFT examples.&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Any help would be appreciated since I am now effectively blocked in automating the NGFW firewall creation.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Regards,&lt;/P&gt;
&lt;P&gt;Shreyas&lt;/P&gt;
&lt;P&gt;&lt;SPAN&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &lt;/SPAN&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Thu, 28 Apr 2022 13:32:11 GMT</pubDate>
      <guid>https://live.paloaltonetworks.com/t5/cloud-ngfw-for-aws-discussions/terraform-ngfw-provider-failing-to-get-token-for/m-p/483472#M276</guid>
      <dc:creator>SZanpure</dc:creator>
      <dc:date>2022-04-28T13:32:11Z</dc:date>
    </item>
    <item>
      <title>Re: Terraform NGFW provider failing to get token for CloudFirewallAdmin</title>
      <link>https://live.paloaltonetworks.com/t5/cloud-ngfw-for-aws-discussions/terraform-ngfw-provider-failing-to-get-token-for/m-p/483584#M277</link>
      <description>&lt;P&gt;Run terraform apply with logging enabled, it might have more information:&lt;BR /&gt;&lt;BR /&gt;&lt;CODE&gt;TF_LOG=debug terraform apply&lt;/CODE&gt;&lt;/P&gt;</description>
      <pubDate>Thu, 28 Apr 2022 17:41:19 GMT</pubDate>
      <guid>https://live.paloaltonetworks.com/t5/cloud-ngfw-for-aws-discussions/terraform-ngfw-provider-failing-to-get-token-for/m-p/483584#M277</guid>
      <dc:creator>gfreeman</dc:creator>
      <dc:date>2022-04-28T17:41:19Z</dc:date>
    </item>
    <item>
      <title>Re: Terraform NGFW provider failing to get token for CloudFirewallAdmin</title>
      <link>https://live.paloaltonetworks.com/t5/cloud-ngfw-for-aws-discussions/terraform-ngfw-provider-failing-to-get-token-for/m-p/483617#M278</link>
      <description>&lt;P&gt;I have been told that the docs are wrong with regards to the tags needed for the role created in AWS.&amp;nbsp; Change the tags as follows:&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;UL&gt;
&lt;LI&gt;CloudFirewallAdmin &amp;gt; CloudNGFWFirewallAdmin&lt;/LI&gt;
&lt;LI&gt;CloudRulestackAdmin &amp;gt; CloudNGFWRulestackAdmin&lt;/LI&gt;
&lt;/UL&gt;</description>
      <pubDate>Thu, 28 Apr 2022 18:43:59 GMT</pubDate>
      <guid>https://live.paloaltonetworks.com/t5/cloud-ngfw-for-aws-discussions/terraform-ngfw-provider-failing-to-get-token-for/m-p/483617#M278</guid>
      <dc:creator>gfreeman</dc:creator>
      <dc:date>2022-04-28T18:43:59Z</dc:date>
    </item>
    <item>
      <title>Re: Terraform NGFW provider failing to get token for CloudFirewallAdmin</title>
      <link>https://live.paloaltonetworks.com/t5/cloud-ngfw-for-aws-discussions/terraform-ngfw-provider-failing-to-get-token-for/m-p/483643#M279</link>
      <description>&lt;P&gt;Thanks&amp;nbsp;&lt;a href="https://live.paloaltonetworks.com/t5/user/viewprofilepage/user-id/46544"&gt;@gfreeman&lt;/a&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;I made changes to the tags, and it made no difference. After switching on TF_LOG, I got an error message which might be of interest to you.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;LI-CODE lang="markup"&gt;-----------------------------------------------------: timestamp=2022-04-28T21:05:56.317+0100
2022-04-28T21:05:56.381+0100 [INFO]  provider.terraform-provider-cloudngfwaws_v1.0.0: 2022/04/28 21:05:56 [DEBUG] CloudNgfwAws API Response Details:
---[ RESPONSE ]--------------------------------------
HTTP/1.1 403 Forbidden
Connection: close
Content-Length: 251
Access-Control-Allow-Headers: Content-Type,X-Amz-Date,Authorization,X-Api-Key,X-Amz-Security-Token,X-Amz-User-Agent
Access-Control-Allow-Methods: *
Access-Control-Allow-Origin: *
Content-Type: application/json
Date: Thu, 28 Apr 2022 20:05:56 GMT
X-Amz-Apigw-Id: &amp;lt;Redacted&amp;gt;
X-Amzn-Errortype: AccessDeniedException
X-Amzn-Requestid: &amp;lt;Redacted&amp;gt;
X-Amzn-Trace-Id: &amp;lt;Redacted&amp;gt;

{
 "message": "User: arn:aws:sts::&amp;lt;Redacted&amp;gt;:assumed-role/palo-ngfw-admin-role/sdk_session is not authorized to perform: execute-api:Invoke on resource: arn:aws:execute-api:us-east-1:********1261:63kpcf9k68/prod/GET/v1/mgmt/tokens/cloudrulestackadmin"
}&lt;/LI-CODE&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;The palo-ngfw-admin-role is setup as such&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;LI-CODE lang="markup"&gt;{
    "Version": "2012-10-17",
    "Statement": [ 
       {
          "Effect": "Allow",
          "Action": [
            "execute-api:Invoke"
          ],
          "Resource": [
            "arn:aws:execute-api:*:*:*"
          ]
      }
    ]
  }&lt;/LI-CODE&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;The assume role policy for assuming the role above is set up as such&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;LI-CODE lang="markup"&gt;{
    "Version": "2012-10-17",
    "Statement": [
      {
        "Sid": "AssumeTaggedRole",
        "Effect": "Allow",
        "Action": "sts:AssumeRole",
        "Principal": {
            "AWS": "arn:aws:iam::${account-id}:root"
        },
        "Condition": {
            "StringEquals": {"iam:ResourceTag/CloudFirewallAdmin": "CloudNGFWFirewallAdmin"}
        }
      }
    ]
  }
  &lt;/LI-CODE&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;The IAM role is set up as&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;LI-CODE lang="markup"&gt;resource "aws_iam_role" "palo-ngfw-admin-role" {
  name               = "palo-ngfw-admin-role"
  assume_role_policy = data.template_file.assume-role-policy.rendered
  tags = {
    "CloudFirewallAdmin"  = "CloudNGFWFirewallAdmin",
    "CloudRulestackAdmin" = "CloudNGFWRulestackAdmin"
  }
}

resource "aws_iam_policy" "palo-nfgw-admin-policy" {
  name   = "palo-nfgw-admin-policy"
  policy = data.template_file.palo-ngfw-admin-policy.rendered
  tags = {
    "Name" = "palo-nfgw-admin-policy"
  }
}

resource "aws_iam_role_policy_attachment" "palo-nfgw-admin-policy-to-palo-ngfw-admin-role" {
  role       = aws_iam_role.palo-ngfw-admin-role.name
  policy_arn = aws_iam_policy.palo-nfgw-admin-policy.arn
}&lt;/LI-CODE&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;The provider config is setup as follows&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;LI-CODE lang="markup"&gt;provider "cloudngfwaws" {
  json_config_file = "./cloudngfwaws_config.json"
}

{
    "host": "api.us-east-1.aws.cloudngfw.paloaltonetworks.com",
    "region": "us-east-1",
    "arn": "arn:aws:iam::&amp;lt;redacted&amp;gt;:role/palo-ngfw-admin-role"
  }&lt;/LI-CODE&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;After all this set up, the IAM user that I use to login to our sandbox account assumes the palo-ngfw-admin-role and tries to execute the api gateway which subsequently fails. Any ideas please?&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Regards,&lt;/P&gt;
&lt;P&gt;Shreyas&lt;/P&gt;</description>
      <pubDate>Thu, 28 Apr 2022 20:31:41 GMT</pubDate>
      <guid>https://live.paloaltonetworks.com/t5/cloud-ngfw-for-aws-discussions/terraform-ngfw-provider-failing-to-get-token-for/m-p/483643#M279</guid>
      <dc:creator>SZanpure</dc:creator>
      <dc:date>2022-04-28T20:31:41Z</dc:date>
    </item>
    <item>
      <title>Re: Terraform NGFW provider failing to get token for CloudFirewallAdmin</title>
      <link>https://live.paloaltonetworks.com/t5/cloud-ngfw-for-aws-discussions/terraform-ngfw-provider-failing-to-get-token-for/m-p/483763#M280</link>
      <description>&lt;P&gt;Looking at that response, it seems like something is misconfigured with your AWS setup.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Found some other documentation and this does actually have the updated role tags that I mentioned above, so maybe there's something in here that's the answer..?&lt;BR /&gt;&lt;BR /&gt;&lt;/P&gt;
&lt;P&gt;&lt;A href="https://pan.dev/cloudngfw/aws/api" target="_blank"&gt;https://pan.dev/cloudngfw/aws/api&lt;/A&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Fri, 29 Apr 2022 04:47:28 GMT</pubDate>
      <guid>https://live.paloaltonetworks.com/t5/cloud-ngfw-for-aws-discussions/terraform-ngfw-provider-failing-to-get-token-for/m-p/483763#M280</guid>
      <dc:creator>gfreeman</dc:creator>
      <dc:date>2022-04-29T04:47:28Z</dc:date>
    </item>
    <item>
      <title>Re: Terraform NGFW provider failing to get token for CloudFirewallAdmin</title>
      <link>https://live.paloaltonetworks.com/t5/cloud-ngfw-for-aws-discussions/terraform-ngfw-provider-failing-to-get-token-for/m-p/483787#M281</link>
      <description>&lt;P&gt;Thanks&amp;nbsp;&lt;a href="https://live.paloaltonetworks.com/t5/user/viewprofilepage/user-id/46544"&gt;@gfreeman&lt;/a&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;That document is exactly the same as&amp;nbsp;&lt;A href="https://docs.paloaltonetworks.com/cloud-ngfw/aws/cloud-ngfw-on-aws/getting-started-with-cloud-ngfw-for-aws/enable-programmatic-access" target="_self"&gt;this&lt;/A&gt;&amp;nbsp;one. The interesting part is that I had set up the tags properly as per that doc, but the result remains the same. Are you sure the perms on the API Gateway in your AWS Account are configured correctly? It might be that you need to re-deploy the API Gateway if you have changed the policies recently on your side. More info&amp;nbsp;&lt;A href="https://stackoverflow.com/questions/53016110/aws-api-gateway-user-anonymous-is-not-authorized-to-execute-api" target="_self"&gt;here&lt;/A&gt;&amp;nbsp;and&amp;nbsp;&lt;A href="https://docs.aws.amazon.com/apigateway/latest/developerguide/apigateway-resource-policies-create-attach.html" target="_self"&gt;here&lt;/A&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="SZanpure_0-1651224933372.png" style="width: 999px;"&gt;&lt;img src="https://live.paloaltonetworks.com/t5/image/serverpage/image-id/40671i5B4AD7F117CF7DC4/image-size/large/is-moderation-mode/true?v=v2&amp;amp;px=999" role="button" title="SZanpure_0-1651224933372.png" alt="SZanpure_0-1651224933372.png" /&gt;&lt;/span&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Here is the IAM Role with the tags&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;LI-CODE lang="markup"&gt;resource "aws_iam_role" "palo-ngfw-admin-role" {
  name               = "palo-ngfw-admin-role"
  assume_role_policy = data.template_file.assume-role-policy.rendered
  tags = {
    "CloudNGFWFirewallAdmin"        = "Create and manage firewalls.",
    "CloudNGFWRulestackAdmin"       = "Create and manage local rulestacks.",
    "CloudNGFWGlobalRulestackAdmin" = "Create and manage global rulestacks."
  }
}&lt;/LI-CODE&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Here is the assume role policy for cloud-firewall-admin&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;LI-CODE lang="markup"&gt;{
    "Version": "2012-10-17",
    "Statement": [
      {
        "Sid": "AssumeTaggedRole",
        "Effect": "Allow",
        "Action": "sts:AssumeRole",
        "Principal": {
            "AWS": "arn:aws:iam::${account-id}:root"
        },
        "Condition": {
            "StringEquals": {"iam:ResourceTag/CloudNGFWFirewallAdmin": "Create and manage firewalls."}
        }
      }
    ]
  }
  &lt;/LI-CODE&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;And the IAM policy is configured exactly as per the doc&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;LI-CODE lang="markup"&gt;{
    "Version": "2012-10-17",
    "Statement": [ 
       {
          "Effect": "Allow",
          "Action": [
            "execute-api:Invoke"
          ],
          "Resource": [
            "arn:aws:execute-api:*:*:*"
          ]
      }
    ]
  }&lt;/LI-CODE&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;From the terraform debug logs, I can see that the role above is being assumed by my IAM user. The NGFW provider API requests are below&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;LI-CODE lang="markup"&gt;2022-04-29T09:45:12.557+0100 [DEBUG] provider: starting plugin: path=.terraform/providers/terraform.local/local/cloudngfwaws/1.0.0/darwin_amd64/terraform-provider-cloudngfwaws_v1.0.0 args=[.terraform/providers/terraform.local/local/cloudngfwaws/1.0.0/darwin_amd64/terraform-provider-cloudngfwaws_v1.0.0]
2022-04-29T09:45:12.562+0100 [DEBUG] provider: plugin started: path=.terraform/providers/terraform.local/local/cloudngfwaws/1.0.0/darwin_amd64/terraform-provider-cloudngfwaws_v1.0.0 pid=43578
2022-04-29T09:45:12.562+0100 [DEBUG] provider: waiting for RPC address: path=.terraform/providers/terraform.local/local/cloudngfwaws/1.0.0/darwin_amd64/terraform-provider-cloudngfwaws_v1.0.0
2022-04-29T09:45:12.575+0100 [INFO]  provider.terraform-provider-cloudngfwaws_v1.0.0: configuring server automatic mTLS: timestamp=2022-04-29T09:45:12.574+0100
2022-04-29T09:45:12.593+0100 [DEBUG] provider: using plugin: version=5
2022-04-29T09:45:12.593+0100 [DEBUG] provider.terraform-provider-cloudngfwaws_v1.0.0: plugin address: address=/var/folders/xb/lm10djv969x0kn2qkt_kpns80000gp/T/plugin580437062 network=unix timestamp=2022-04-29T09:45:12.593+0100
2022-04-29T09:45:12.626+0100 [WARN]  ValidateProviderConfig from "provider[\"registry.terraform.io/hashicorp/aws\"]" changed the config value, but that value is unused
2022-04-29T09:45:12.630+0100 [DEBUG] No provider meta schema returned
2022-04-29T09:45:12.632+0100 [DEBUG] provider.terraform-provider-aws_v4.10.0_x5: Using profile from configuration: "sandbox-networking": timestamp=2022-04-29T09:45:12.631+0100
2022-04-29T09:45:12.632+0100 [INFO]  provider.terraform-provider-aws_v4.10.0_x5: Retrieved credentials from "SharedConfigCredentials: /Users/Shreyas.Zanpure/.aws/credentials": timestamp=2022-04-29T09:45:12.632+0100
2022-04-29T09:45:12.632+0100 [DEBUG] provider.terraform-provider-aws_v4.10.0_x5: Trying to get account information via sts:GetCallerIdentity: timestamp=2022-04-29T09:45:12.632+0100
2022-04-29T09:45:12.633+0100 [INFO]  ReferenceTransformer: reference not found: "path.module"
2022-04-29T09:45:12.633+0100 [DEBUG] ReferenceTransformer: "module.base.data.template_file.init" references: []
2022-04-29T09:45:12.633+0100 [DEBUG] provider.terraform-provider-aws_v4.10.0_x5: [aws-sdk-go-v2] Request
POST / HTTP/1.1
Host: sts.us-east-1.amazonaws.com
User-Agent: APN/1.0 HashiCorp/1.0 Terraform/1.0.7 (+https://www.terraform.io) terraform-provider-aws/dev (+https://registry.terraform.io/providers/hashicorp/aws) aws-sdk-go-v2/1.16.2 os/macos lang/go/1.17.6 md/GOOS/darwin md/GOARCH/amd64 api/sts/1.16.0
Content-Length: 43
Amz-Sdk-Invocation-Id: 8334faa7-d169-43e6-b42f-c4029b5ce990
Amz-Sdk-Request: attempt=1; max=25
Authorization: AWS4-HMAC-SHA256 Credential=AKIAWZZ3MAPME2WKYNVE/20220429/us-east-1/sts/aws4_request, SignedHeaders=amz-sdk-invocation-id;amz-sdk-request;content-length;content-type;host;x-amz-date, Signature=624cd938ef86b60469f73a6219155b8a76b6bdf77b10d6c16e14d566b0326025
Content-Type: application/x-www-form-urlencoded
X-Amz-Date: 20220429T084512Z
Accept-Encoding: gzip

Action=GetCallerIdentity&amp;amp;Version=2011-06-15: timestamp=2022-04-29T09:45:12.633+0100
2022-04-29T09:45:12.633+0100 [INFO]  ReferenceTransformer: reference not found: "path.module"
2022-04-29T09:45:12.633+0100 [INFO]  ReferenceTransformer: reference not found: "var.account-id"
2022-04-29T09:45:12.633+0100 [DEBUG] ReferenceTransformer: "module.base.data.template_file.assume-role-policy" references: []
2022-04-29T09:45:12.633+0100 [INFO]  ReferenceTransformer: reference not found: "path.module"
2022-04-29T09:45:12.633+0100 [DEBUG] ReferenceTransformer: "module.base.data.template_file.palo-ngfw-admin-policy" references: []
2022-04-29T09:45:12.636+0100 [INFO]  provider.terraform-provider-cloudngfwaws_v1.0.0: 2022/04/29 09:45:12 (login) refreshing JWTs...: timestamp=2022-04-29T09:45:12.636+0100
2022-04-29T09:45:12.636+0100 [INFO]  provider.terraform-provider-cloudngfwaws_v1.0.0: 2022/04/29 09:45:12 (login) refreshing rulestack JWT...: timestamp=2022-04-29T09:45:12.636+0100
2022-04-29T09:45:12.637+0100 [INFO]  provider.terraform-provider-cloudngfwaws_v1.0.0: 2022/04/29 09:45:12 (login) refreshing firewall JWT...: timestamp=2022-04-29T09:45:12.637+0100
2022-04-29T09:45:12.637+0100 [DEBUG] provider: plugin process exited: path=.terraform/providers/registry.terraform.io/hashicorp/template/2.2.0/darwin_amd64/terraform-provider-template_v2.2.0_x4 pid=43577
2022-04-29T09:45:12.637+0100 [DEBUG] provider: plugin exited
2022-04-29T09:45:13.007+0100 [INFO]  provider.terraform-provider-cloudngfwaws_v1.0.0: 2022/04/29 09:45:13 [DEBUG] CloudNgfwAws API Request Details:
---[ REQUEST ]---------------------------------------
GET /v1/mgmt/tokens/cloudrulestackadmin HTTP/1.1
Host: api.us-east-1.aws.cloudngfw.paloaltonetworks.com
User-Agent: Terraform/1.0.7 (+https://www.terraform.io) Terraform-Plugin-SDK/2.10.1 terraform-provider-cloudngfwaws/dev
Content-Length: 65
Authorization: AWS4-HMAC-SHA256 Credential=ASIAWZZ3MAPMJZ4GVKG6/20220429/us-east-1/execute-api/aws4_request, SignedHeaders=content-type;host;x-amz-date;x-amz-security-token, Signature=e13e27cac4a60e4b93e1948cda678f21a2831a12b81d7c0bbbc8aac4cbdae8c7
Content-Type: application/json
X-Amz-Date: 20220429T084513Z
X-Amz-Security-Token: FwoGZXIvYXdzEEIaDHY/DJ8ESp2CSON+3iKvAbnQ+A3+se4jEjoXRmzrYU1olbKNc+ABgEKeNMXKwWLvZ4+YXb3Omorva6Y+E9RkJXOvbCT7iuY2N9nxu/pNri1E7pAGEchHkOQ4slk2C0K2vPipEVg3eKyUxtch7WynS51SeY04RP4qZipcF/UPzTM2OPo3EFL3lWqDH314tkIUdXVZ9UUidvabu/dhzyRUh+OeJaZCu1KPBdB5xoZr1mKz5DAVZcsQjaQXbShCH/comcuukwYyLaCDABerF3X0zuEAEnNHpDZXMbvrHHI8/MFXtA41UTFHmDrKsjkWiacLv/s86g==
Accept-Encoding: gzip

{
 "ExpiryTime": 120,
 "KeyInfo": {
  "Region": "us-east-1",
  "Tenant": "XY"
 }
}
-----------------------------------------------------: timestamp=2022-04-29T09:45:13.006+0100
2022-04-29T09:45:13.013+0100 [INFO]  provider.terraform-provider-cloudngfwaws_v1.0.0: 2022/04/29 09:45:13 [DEBUG] CloudNgfwAws API Request Details:
---[ REQUEST ]---------------------------------------
GET /v1/mgmt/tokens/cloudfirewalladmin HTTP/1.1
Host: api.us-east-1.aws.cloudngfw.paloaltonetworks.com
User-Agent: Terraform/1.0.7 (+https://www.terraform.io) Terraform-Plugin-SDK/2.10.1 terraform-provider-cloudngfwaws/dev
Content-Length: 65
Authorization: AWS4-HMAC-SHA256 Credential=ASIAWZZ3MAPMAVXHJH5M/20220429/us-east-1/execute-api/aws4_request, SignedHeaders=content-type;host;x-amz-date;x-amz-security-token, Signature=c25896b944eb1d50da387e0b28ad5e80c5a582f2baa1f8c580bacdf2f1a93bba
Content-Type: application/json
X-Amz-Date: 20220429T084513Z
X-Amz-Security-Token: FwoGZXIvYXdzEEIaDNTbGd35gptfaUWX+yKvARSKRrecP/LfUW+zY3HdQ2K/VdipSABiLgEP9o/tzb+MF2U/LxZ0AsSfl24+54TTbnVils9715vgwC27Pz+tc5rpF/gGHRkPH6Mh+iN0wio1h7Ts3mhfvhUAdX22+sgB1L6uSfLVX3+t/maUVSPqnORoZRJ6Bzk7c+0nb9h0FHWogvQXoIIp/6gWvoObSxAwUf+LBU3vDM6mZI2/pmkseJadGox7lYHT/gzmljW/7+komcuukwYyLQs7Qtr30KYv9mgPOi4eIszwncrby1xF0QblenvW1dpTgvEdIwiSjBzmVuf2xA==
Accept-Encoding: gzip

{
 "ExpiryTime": 120,
 "KeyInfo": {
  "Region": "us-east-1",
  "Tenant": "XY"
 }
}
&lt;/LI-CODE&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;As you can see, the provider tries to refresh JWT for both firewalladmin and rulestackadmin. The responses are below&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;LI-CODE lang="markup"&gt;2022-04-29T09:45:13.452+0100 [INFO]  provider.terraform-provider-cloudngfwaws_v1.0.0: 2022/04/29 09:45:13 [DEBUG] CloudNgfwAws API Response Details:
---[ RESPONSE ]--------------------------------------
HTTP/1.1 403 Forbidden
Connection: close
Content-Length: 250
Access-Control-Allow-Headers: Content-Type,X-Amz-Date,Authorization,X-Api-Key,X-Amz-Security-Token,X-Amz-User-Agent
Access-Control-Allow-Methods: *
Access-Control-Allow-Origin: *
Content-Type: application/json
Date: Fri, 29 Apr 2022 08:45:13 GMT
X-Amz-Apigw-Id: RVbQAHLYoAMF4eg=
X-Amzn-Errortype: AccessDeniedException
X-Amzn-Requestid: 2f112342-1b79-4ed9-9f47-5dc322991474
X-Amzn-Trace-Id: Root=1-626ba599-385c55af49a880b737155da7

{
 "message": "User: arn:aws:sts::467739083736:assumed-role/palo-ngfw-admin-role/sdk_session is not authorized to perform: execute-api:Invoke on resource: arn:aws:execute-api:us-east-1:********1261:63kpcf9k68/prod/GET/v1/mgmt/tokens/cloudfirewalladmin"
}
-----------------------------------------------------: timestamp=2022-04-29T09:45:13.452+0100
2022-04-29T09:45:13.453+0100 [INFO]  provider.terraform-provider-cloudngfwaws_v1.0.0: 2022/04/29 09:45:13 [DEBUG] CloudNgfwAws API Response Details:
---[ RESPONSE ]--------------------------------------
HTTP/1.1 403 Forbidden
Connection: close
Content-Length: 251
Access-Control-Allow-Headers: Content-Type,X-Amz-Date,Authorization,X-Api-Key,X-Amz-Security-Token,X-Amz-User-Agent
Access-Control-Allow-Methods: *
Access-Control-Allow-Origin: *
Content-Type: application/json
Date: Fri, 29 Apr 2022 08:45:13 GMT
X-Amz-Apigw-Id: RVbQAEDdoAMFlrw=
X-Amzn-Errortype: AccessDeniedException
X-Amzn-Requestid: 0544aee5-fcad-4bdd-8409-1017e4c4690e
X-Amzn-Trace-Id: Root=1-626ba599-539f933c60fb6d616b9c83b9

{
 "message": "User: arn:aws:sts::467739083736:assumed-role/palo-ngfw-admin-role/sdk_session is not authorized to perform: execute-api:Invoke on resource: arn:aws:execute-api:us-east-1:********1261:63kpcf9k68/prod/GET/v1/mgmt/tokens/cloudrulestackadmin"
}&lt;/LI-CODE&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;At this point I am not really sure what is mis-configured on my side. I have followed the docs as mentioned. Also the link for this repo&amp;nbsp;&lt;A href="https://github.com/PaloAltoNetworks/CloudNGFW-AWS-Examples" target="_blank" rel="noopener"&gt;https://github.com/PaloAltoNetworks/CloudNGFW-AWS-Examples&lt;/A&gt;&amp;nbsp;seems to be broken (mentioned in step 6 of the guide I linked at the beginning of this post), so I cannot look at the CFT examples either.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Regards,&lt;/P&gt;
&lt;P&gt;Shreyas&lt;/P&gt;</description>
      <pubDate>Fri, 29 Apr 2022 09:36:44 GMT</pubDate>
      <guid>https://live.paloaltonetworks.com/t5/cloud-ngfw-for-aws-discussions/terraform-ngfw-provider-failing-to-get-token-for/m-p/483787#M281</guid>
      <dc:creator>SZanpure</dc:creator>
      <dc:date>2022-04-29T09:36:44Z</dc:date>
    </item>
    <item>
      <title>Re: Terraform NGFW provider failing to get token for CloudFirewallAdmin</title>
      <link>https://live.paloaltonetworks.com/t5/cloud-ngfw-for-aws-discussions/terraform-ngfw-provider-failing-to-get-token-for/m-p/483821#M282</link>
      <description>&lt;P&gt;OK, two things:&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;First is that I think the value of the tag is the important bit, not the key name.&amp;nbsp; In my setup, the keys are actually named "CloudNGFWFirewallAdmin1" and "CloudNgfwRulestackAdmin".&amp;nbsp; Try setting the values to the values mentioned in the 2nd link I provided and see if that changes the result.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Second, since you are essentially stuck at, "I'm trying to enable API access," this is fully supported TAC territory.&amp;nbsp; If you have a support contract with Palo Alto Networks in place, then I'd encourage you to reach out to TAC for help.&amp;nbsp; The Terraform provider is unreleased currently and should otherwise be considered beta code, but enabling API access has nothing to do with the provider.&lt;/P&gt;</description>
      <pubDate>Fri, 29 Apr 2022 16:24:41 GMT</pubDate>
      <guid>https://live.paloaltonetworks.com/t5/cloud-ngfw-for-aws-discussions/terraform-ngfw-provider-failing-to-get-token-for/m-p/483821#M282</guid>
      <dc:creator>gfreeman</dc:creator>
      <dc:date>2022-04-29T16:24:41Z</dc:date>
    </item>
    <item>
      <title>Re: Terraform NGFW provider failing to get token for CloudFirewallAdmin</title>
      <link>https://live.paloaltonetworks.com/t5/cloud-ngfw-for-aws-discussions/terraform-ngfw-provider-failing-to-get-token-for/m-p/483828#M283</link>
      <description>&lt;P&gt;Oh sorry, another thing:&amp;nbsp; I just noticed that in your error message, the ARN looks different from mine, but there's enough stuff going on that I don't know if this is a result of how the AWS SDK formats things or not.&amp;nbsp; And looking back, it does seem like you're using the ARN of the IAM role, but I just wanted to make sure...&amp;nbsp; The ARN that I specify in the provider configure block looks like this, just wanted to be certain that's what yours looks like also (I was using two different ARNs instead of a single one):&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;LI-CODE lang="markup"&gt;provider "cloudngfwaws" {
    lfa_arn = "arn:aws:iam::&amp;lt;number&amp;gt;:role/CloudNGFWFirewallAdmin1"
    lra_arn = "arn:aws:iam::&amp;lt;number&amp;gt;:role/CloudNgfwRuleStackAdmin"
    #....  other params
}
&lt;/LI-CODE&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Fri, 29 Apr 2022 16:42:15 GMT</pubDate>
      <guid>https://live.paloaltonetworks.com/t5/cloud-ngfw-for-aws-discussions/terraform-ngfw-provider-failing-to-get-token-for/m-p/483828#M283</guid>
      <dc:creator>gfreeman</dc:creator>
      <dc:date>2022-04-29T16:42:15Z</dc:date>
    </item>
    <item>
      <title>Re: Terraform NGFW provider failing to get token for CloudFirewallAdmin</title>
      <link>https://live.paloaltonetworks.com/t5/cloud-ngfw-for-aws-discussions/terraform-ngfw-provider-failing-to-get-token-for/m-p/483831#M284</link>
      <description>NBS Internal&lt;BR /&gt;&lt;BR /&gt;Hi,&lt;BR /&gt;&lt;BR /&gt;Would it be possible for you to supply the exact values of the “tag KV pairs” for the IAM role please? I have put the exact key/values for the tags from the article you linked to, where the value seems to be a sort of a description of the key. It would help clarify things a bit.&lt;BR /&gt;&lt;BR /&gt;We do have a support contract as part of “Nationwide Building Society”, so I will try and find someone who can help me under that.&lt;BR /&gt;&lt;BR /&gt;Thanks,&lt;BR /&gt;Shreyas.&lt;BR /&gt;</description>
      <pubDate>Fri, 29 Apr 2022 16:56:04 GMT</pubDate>
      <guid>https://live.paloaltonetworks.com/t5/cloud-ngfw-for-aws-discussions/terraform-ngfw-provider-failing-to-get-token-for/m-p/483831#M284</guid>
      <dc:creator>SZanpure</dc:creator>
      <dc:date>2022-04-29T16:56:04Z</dc:date>
    </item>
    <item>
      <title>Re: Terraform NGFW provider failing to get token for CloudFirewallAdmin</title>
      <link>https://live.paloaltonetworks.com/t5/cloud-ngfw-for-aws-discussions/terraform-ngfw-provider-failing-to-get-token-for/m-p/483860#M285</link>
      <description>&lt;P&gt;I can't share my config, unfortunately.....&amp;nbsp; But I'm glad that you can engage TAC for figuring out API access.&lt;/P&gt;</description>
      <pubDate>Fri, 29 Apr 2022 18:22:36 GMT</pubDate>
      <guid>https://live.paloaltonetworks.com/t5/cloud-ngfw-for-aws-discussions/terraform-ngfw-provider-failing-to-get-token-for/m-p/483860#M285</guid>
      <dc:creator>gfreeman</dc:creator>
      <dc:date>2022-04-29T18:22:36Z</dc:date>
    </item>
    <item>
      <title>Re: Terraform NGFW provider failing to get token for CloudFirewallAdmin</title>
      <link>https://live.paloaltonetworks.com/t5/cloud-ngfw-for-aws-discussions/terraform-ngfw-provider-failing-to-get-token-for/m-p/484471#M286</link>
      <description>&lt;P&gt;It looks like the docs have been updated now along with provider (as you mentioned) with the correct tags and steps. I will try these out now and report back. Thanks &lt;span class="lia-unicode-emoji" title=":slightly_smiling_face:"&gt;🙂&lt;/span&gt;&lt;/P&gt;
&lt;P&gt;EDIT: I have got it working now. There is one another tweak that needs to be done. The KeyInfo property on line 14 in getJwtStruct needs to be commented out&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&lt;A href="https://github.com/PaloAltoNetworks/cloud-ngfw-aws-go/blob/main/auth.go" target="_blank"&gt;https://github.com/PaloAltoNetworks/cloud-ngfw-aws-go/blob/main/auth.go&lt;/A&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;This is because the commit made&amp;nbsp;&lt;A href="https://github.com/PaloAltoNetworks/cloud-ngfw-aws-go/commit/62b47259d9a1e9399760565ce2af44e93db4cb54?diff=unified" target="_self"&gt;here&lt;/A&gt;&amp;nbsp;commented out the code supplying the property value. After I commented out the property locally, I rebuilt the provider, and I was able to run &lt;EM&gt;'terraform plan'&lt;/EM&gt; successfully &lt;span class="lia-unicode-emoji" title=":slightly_smiling_face:"&gt;🙂&lt;/span&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;The error I was getting without commenting out KeyInfo was&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;LI-CODE lang="markup"&gt;ValidationError: 1 validation error for GetCloudFirewallAdminRequest
KeyInfo
  extra fields not permitted (type=value_error.extra)&lt;/LI-CODE&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;After commenting out, I got successful JWT generation and terraform plan out as follows&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;LI-CODE lang="markup"&gt;2022-05-03T11:37:08.302+0100 [INFO]  provider.terraform-provider-cloudngfwaws_v1.0.0: 2022/05/03 11:37:08 sending: {"ExpiryTime":120}: timestamp=2022-05-03T11:37:08.302+0100
2022-05-03T11:37:08.302+0100 [INFO]  provider.terraform-provider-cloudngfwaws_v1.0.0: 2022/05/03 11:37:08 path: https://api.us-east-1.aws.cloudngfw.paloaltonetworks.com/v1/mgmt/tokens/cloudfirewalladmin: timestamp=2022-05-03T11:37:08.302+0100
2022-05-03T11:37:08.302+0100 [INFO]  provider.terraform-provider-cloudngfwaws_v1.0.0: 2022/05/03 11:37:08 [DEBUG] CloudNgfwAws API Request Details:
---[ REQUEST ]---------------------------------------
GET /v1/mgmt/tokens/cloudfirewalladmin HTTP/1.1
Host: api.us-east-1.aws.cloudngfw.paloaltonetworks.com
User-Agent: Terraform/1.0.7 (+https://www.terraform.io) Terraform-Plugin-SDK/2.10.1 terraform-provider-cloudngfwaws/dev
Content-Length: 18
Authorization: AWS4-HMAC-SHA256 Credential=&amp;lt;redacted&amp;gt;/20220503/us-east-1/execute-api/aws4_request, SignedHeaders=content-type;host;x-amz-date;x-amz-security-token, Signature=&amp;lt;redacted&amp;gt;
Content-Type: application/json
X-Amz-Date: 20220503T103708Z
X-Amz-Security-Token: &amp;lt;redacted&amp;gt;
Accept-Encoding: gzip

{
 "ExpiryTime": 120
}

2022-05-03T11:37:11.650+0100 [INFO]  provider.terraform-provider-cloudngfwaws_v1.0.0: 2022/05/03 11:37:11 [DEBUG] CloudNgfwAws API Response Details:
---[ RESPONSE ]--------------------------------------
HTTP/1.1 200 OK
Connection: close
Content-Length: 874
Access-Control-Allow-Origin: *
Cache-Control: no-store
Content-Security-Policy: frame-ancestors none
Content-Type: application/json
Date: Tue, 03 May 2022 10:37:11 GMT
Strict-Transport-Security: max-age=31536000
X-Amz-Apigw-Id: &amp;lt;redacted&amp;gt;
X-Amzn-Requestid: 12db701d-62b9-4097-9a1b-3a8d509c86f2
X-Amzn-Trace-Id: Root=1-627105d4-122e8dba707e6988101c1aa8
X-Content-Type-Options: no-sniff
X-Frame-Options: DENY

{
 "Response": {
  "TokenId": &amp;lt;redacted&amp;gt;,
  "SubscriptionKey": &amp;lt;redacted&amp;gt;,
  "ExpiryTime": 120,
  "Enabled": true
 },
 "ResponseStatus": {
  "ErrorCode": 0
 }
}&lt;/LI-CODE&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;LI-CODE lang="markup"&gt;Terraform will perform the following actions:

  # module.base.cloudngfwaws_commit_rulestack.example will be created
  + resource "cloudngfwaws_commit_rulestack" "example" {
      + commit_errors     = (known after apply)
      + commit_status     = (known after apply)
      + id                = (known after apply)
      + rulestack         = "test-rulestack-terraform"
      + state             = "Running"
      + validation_errors = (known after apply)
      + validation_status = (known after apply)
    }

  # module.base.cloudngfwaws_ngfw.test-ngfw-terraform will be created
  + resource "cloudngfwaws_ngfw" "test-ngfw-terraform" {
      + account_id                       = "467739083736"
      + app_id_version                   = (known after apply)
      + automatic_upgrade_app_id_version = true
      + description                      = "Test NGFW created via terraform provider"
      + endpoint_mode                    = "CustomerManaged"
      + id                               = (known after apply)
      + name                             = "test-ngfw-terraform"
      + rulestack                        = "test-rulestack-terraform"
      + tags                             = {
          + "Foo" = "bar"
        }
      + update_token                     = (known after apply)
      + vpc_id                           = "vpc-0f9f37d5ba25bf53e"

      + subnet_mapping {
          + subnet_id = "subnet-063a57e75839ba2ba"
        }
      + subnet_mapping {
          + subnet_id = "subnet-016286207f6cede42"
        }
    }

  # module.base.cloudngfwaws_rulestack.test-rulestack-terraform will be created
  + resource "cloudngfwaws_rulestack" "test-rulestack-terraform" {
      + account_id             = "467739083736"
      + description            = "Test rulestack created via terraform provider"
      + id                     = (known after apply)
      + minimum_app_id_version = (known after apply)
      + name                   = "test-rulestack-terraform"
      + scope                  = "Local"
      + state                  = (known after apply)

      + profile_config {
          + anti_spyware  = "BestPractice"
          + anti_virus    = "BestPractice"
          + file_blocking = "BestPractice"
          + url_filtering = "None"
          + vulnerability = "BestPractice"
        }
    }

  # module.base.cloudngfwaws_security_rule.test-security-rule-terraform will be created
  + resource "cloudngfwaws_security_rule" "test-security-rule-terraform" {
      + action             = "Allow"
      + applications       = [
          + "any",
        ]
      + audit_comment      = "initial config"
      + description        = "Test security rule created via terraform provider"
      + enabled            = true
      + id                 = (known after apply)
      + logging            = true
      + name               = "test-security-rule-terraform"
      + negate_destination = true
      + priority           = 1
      + protocol           = "application-default"
      + rule_list          = "LocalRule"
      + rulestack          = "test-rulestack-terraform"
      + tags               = (known after apply)
      + update_token       = (known after apply)

      + category {}

      + destination {
          + cidrs = [
              + "any",
            ]
        }

      + source {
          + cidrs = [
              + "any",
            ]
        }
    }

Plan: 4 to add, 0 to change, 0 to destroy.&lt;/LI-CODE&gt;</description>
      <pubDate>Tue, 03 May 2022 10:51:21 GMT</pubDate>
      <guid>https://live.paloaltonetworks.com/t5/cloud-ngfw-for-aws-discussions/terraform-ngfw-provider-failing-to-get-token-for/m-p/484471#M286</guid>
      <dc:creator>SZanpure</dc:creator>
      <dc:date>2022-05-03T10:51:21Z</dc:date>
    </item>
    <item>
      <title>Re: Terraform NGFW provider failing to get token for CloudFirewallAdmin</title>
      <link>https://live.paloaltonetworks.com/t5/cloud-ngfw-for-aws-discussions/terraform-ngfw-provider-failing-to-get-token-for/m-p/484555#M287</link>
      <description>&lt;P&gt;I keep forgetting how golang treats XML and JSON is not the same.&amp;nbsp; Ok, this should be fixed now, just re-pull and SDK and the provider.&amp;nbsp; I added NGFW tagging and rulestack tagging last night.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Awesome to hear it's working for you!&lt;/P&gt;</description>
      <pubDate>Tue, 03 May 2022 16:57:08 GMT</pubDate>
      <guid>https://live.paloaltonetworks.com/t5/cloud-ngfw-for-aws-discussions/terraform-ngfw-provider-failing-to-get-token-for/m-p/484555#M287</guid>
      <dc:creator>gfreeman</dc:creator>
      <dc:date>2022-05-03T16:57:08Z</dc:date>
    </item>
    <item>
      <title>Re: Terraform NGFW provider failing to get token for CloudFirewallAdmin</title>
      <link>https://live.paloaltonetworks.com/t5/cloud-ngfw-for-aws-discussions/terraform-ngfw-provider-failing-to-get-token-for/m-p/484590#M288</link>
      <description>&lt;DIV dir="ltr"&gt;Thanks &lt;span class="lia-unicode-emoji" title=":slightly_smiling_face:"&gt;🙂&lt;/span&gt;&lt;/DIV&gt;
&lt;DIV dir="ltr"&gt;I did get stuck on another thing though. The rulestack resource execution was followed by commit_rulestack resource. The default state is set to Running. However, when the NFGW resource was being created, I had a timeout after around 5 minutes and 30 seconds. When I ran tf plan once more, tf wanted to change state from “precommitdone” to “running” (due to default state in terraform resource block being “running” and state on Palo NGFW UI being “precommitdone”. I wasn’t able to run terraform apply again due to recurring error&amp;nbsp;&lt;/DIV&gt;
&lt;DIV dir="ltr"&gt;&amp;nbsp;&lt;/DIV&gt;
&lt;DIV dir="ltr"&gt;&lt;LI-CODE lang="markup"&gt;module.base.cloudngfwaws_commit_rulestack.commit-test-rulestack-terraform: Creating...
╷
│ Error: Error(1): Commit process unfinished.
│ 
│   with module.base.cloudngfwaws_commit_rulestack.commit-test-rulestack-terraform,
│   on modules/base/palo-ngfw.tf line 33, in resource "cloudngfwaws_commit_rulestack" "commit-test-rulestack-terraform":
│   33: resource "cloudngfwaws_commit_rulestack" "commit-test-rulestack-terraform" {&lt;/LI-CODE&gt;&lt;/DIV&gt;
&lt;DIV dir="ltr"&gt;&amp;nbsp;&lt;/DIV&gt;
&lt;DIV dir="ltr"&gt;I am also unable to delete the rulestack from NGFW UI.&lt;/DIV&gt;
&lt;DIV dir="ltr"&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="SZanpure_0-1651603551332.png" style="width: 999px;"&gt;&lt;img src="https://live.paloaltonetworks.com/t5/image/serverpage/image-id/40833i9D8C8178E65AC641/image-size/large/is-moderation-mode/true?v=v2&amp;amp;px=999" role="button" title="SZanpure_0-1651603551332.png" alt="SZanpure_0-1651603551332.png" /&gt;&lt;/span&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;/DIV&gt;
&lt;DIV dir="ltr"&gt;Have you encountered this? The docs suggest that I should look at the read-only properties on the rulestack to find it’s status, which can be done via output vars, but does mean that all ruelstacks need to be defined in their own module?&lt;/DIV&gt;
&lt;DIV dir="ltr"&gt;It would be great if the docs could include an example of some sort dependency, where NGFW is created only after rulestack has switched to a status of “Running” in Palo UI, instead of setting the default state in terraform which does not truly reflect the state in Palo UI. Hope that makes sense.&lt;/DIV&gt;
&lt;DIV dir="ltr"&gt;&amp;nbsp;&lt;/DIV&gt;
&lt;DIV dir="ltr"&gt;Thanks,&lt;/DIV&gt;
&lt;DIV dir="ltr"&gt;Shreyas&amp;nbsp;&lt;/DIV&gt;</description>
      <pubDate>Tue, 03 May 2022 18:46:07 GMT</pubDate>
      <guid>https://live.paloaltonetworks.com/t5/cloud-ngfw-for-aws-discussions/terraform-ngfw-provider-failing-to-get-token-for/m-p/484590#M288</guid>
      <dc:creator>SZanpure</dc:creator>
      <dc:date>2022-05-03T18:46:07Z</dc:date>
    </item>
    <item>
      <title>Re: Terraform NGFW provider failing to get token for CloudFirewallAdmin</title>
      <link>https://live.paloaltonetworks.com/t5/cloud-ngfw-for-aws-discussions/terraform-ngfw-provider-failing-to-get-token-for/m-p/484957#M289</link>
      <description>&lt;P&gt;You shouldn't have &lt;CODE&gt;cloudngfwaws_commit_rulestack&lt;/CODE&gt; in the same plan file as &lt;CODE&gt;cloudngfwaws_rulestack&lt;/CODE&gt;, this is called out in the docs.&amp;nbsp; This is because of the order of operations that Terraform does things in, there will always be, what is referred to in Terraform, as "configuration drift."&amp;nbsp; Commit rulestack needs to be in its own plan file, but can be paired with other commit rulestack operations.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;The commit rulestack resource has 15min set as the timeout, so I don't know why it timed out after 5min...?&amp;nbsp; I've also not encountered PrecommitDone sticking around for a long time, but I suspect at this point it is no longer in this state..?&lt;/P&gt;</description>
      <pubDate>Wed, 04 May 2022 16:16:31 GMT</pubDate>
      <guid>https://live.paloaltonetworks.com/t5/cloud-ngfw-for-aws-discussions/terraform-ngfw-provider-failing-to-get-token-for/m-p/484957#M289</guid>
      <dc:creator>gfreeman</dc:creator>
      <dc:date>2022-05-04T16:16:31Z</dc:date>
    </item>
    <item>
      <title>Re: Terraform NGFW provider failing to get token for CloudFirewallAdmin</title>
      <link>https://live.paloaltonetworks.com/t5/cloud-ngfw-for-aws-discussions/terraform-ngfw-provider-failing-to-get-token-for/m-p/484958#M290</link>
      <description>&lt;P&gt;Actually, I've only seen SUCCESS / FAILURE / PENDING, I've not seen PrecommitDone before.&amp;nbsp; If you do &lt;CODE&gt;terraform refresh&lt;/CODE&gt; / &lt;CODE&gt;terraform show&lt;/CODE&gt;, is it showing that the &lt;CODE&gt;cloudngfwaws_commit_rulestack.(terraform_name).CommitStatus&lt;/CODE&gt; is PrecommitDone...??&lt;/P&gt;</description>
      <pubDate>Wed, 04 May 2022 16:22:09 GMT</pubDate>
      <guid>https://live.paloaltonetworks.com/t5/cloud-ngfw-for-aws-discussions/terraform-ngfw-provider-failing-to-get-token-for/m-p/484958#M290</guid>
      <dc:creator>gfreeman</dc:creator>
      <dc:date>2022-05-04T16:22:09Z</dc:date>
    </item>
    <item>
      <title>Re: Terraform NGFW provider failing to get token for CloudFirewallAdmin</title>
      <link>https://live.paloaltonetworks.com/t5/cloud-ngfw-for-aws-discussions/terraform-ngfw-provider-failing-to-get-token-for/m-p/484965#M291</link>
      <description>NBS Internal&lt;BR /&gt;&lt;BR /&gt;Thanks for the info. I have run terraform plan multiple times and the rulestack commit status is “PreCommitDone”. I am unable to delete it from the UI since it gives that error in the previously posted screenshot. I will look to moving commit_rulestack to separate plan, which means that NGFW resource will need to be in its own plan as well? It has a dependency on the rullestack being committed before the NGFW is successfully deployed.&lt;BR /&gt;</description>
      <pubDate>Wed, 04 May 2022 17:16:33 GMT</pubDate>
      <guid>https://live.paloaltonetworks.com/t5/cloud-ngfw-for-aws-discussions/terraform-ngfw-provider-failing-to-get-token-for/m-p/484965#M291</guid>
      <dc:creator>SZanpure</dc:creator>
      <dc:date>2022-05-04T17:16:33Z</dc:date>
    </item>
    <item>
      <title>Re: Terraform NGFW provider failing to get token for CloudFirewallAdmin</title>
      <link>https://live.paloaltonetworks.com/t5/cloud-ngfw-for-aws-discussions/terraform-ngfw-provider-failing-to-get-token-for/m-p/484966#M292</link>
      <description>&lt;P&gt;...huh.&amp;nbsp; Is the rulestack associated with a NGFW which you've spun up?&amp;nbsp; If so, you might have to bring down / delete that NGFW before you can delete the rulestack.&lt;/P&gt;</description>
      <pubDate>Wed, 04 May 2022 17:22:47 GMT</pubDate>
      <guid>https://live.paloaltonetworks.com/t5/cloud-ngfw-for-aws-discussions/terraform-ngfw-provider-failing-to-get-token-for/m-p/484966#M292</guid>
      <dc:creator>gfreeman</dc:creator>
      <dc:date>2022-05-04T17:22:47Z</dc:date>
    </item>
    <item>
      <title>Re: Terraform NGFW provider failing to get token for CloudFirewallAdmin</title>
      <link>https://live.paloaltonetworks.com/t5/cloud-ngfw-for-aws-discussions/terraform-ngfw-provider-failing-to-get-token-for/m-p/484970#M293</link>
      <description>&lt;P&gt;NBS Internal&lt;BR /&gt;&lt;BR /&gt;Yes. If you look at the terraform plan output from previous posts, I am attempting creation of barebones firewall, with a rulestack that has a single security rule.&lt;BR /&gt;&lt;BR /&gt;So, in my head I understand the execution sequence as&lt;BR /&gt;&lt;BR /&gt;1. Rule is created&lt;BR /&gt;2. Rulestack is created with the above rule&lt;BR /&gt;3. Rulestack needs to be committed.&lt;BR /&gt;4. Rulestack is associated with the NGFW&lt;BR /&gt;5. NGFW is created.&lt;BR /&gt;&lt;BR /&gt;In my case, I believe I am stuck at step 3. Rulestack is not properly committed, and hence the first time around, NGFW creation in “tf apply” ran for 5 minutes and 30 seconds before timing out. Now I am not sure if “tf apply” on NGFW was waiting internally on Commit_Rulestack to finish or it was waiting for its own creation.&lt;BR /&gt;&lt;BR /&gt;Another thing to note is that in the UI my NGFW via terraform appeared in CREATE_FAIL status (after 5.5 minutes timeout).&lt;BR /&gt;I was able to delete the firewall in the UI, but unable to delete the rule stack.&lt;BR /&gt;&lt;BR /&gt;I will investigate creation of separate tfstate/plan for rulestack and commit_rulestack.&lt;/P&gt;</description>
      <pubDate>Wed, 04 May 2022 17:51:39 GMT</pubDate>
      <guid>https://live.paloaltonetworks.com/t5/cloud-ngfw-for-aws-discussions/terraform-ngfw-provider-failing-to-get-token-for/m-p/484970#M293</guid>
      <dc:creator>SZanpure</dc:creator>
      <dc:date>2022-05-04T17:51:39Z</dc:date>
    </item>
    <item>
      <title>Re: Terraform NGFW provider failing to get token for CloudFirewallAdmin</title>
      <link>https://live.paloaltonetworks.com/t5/cloud-ngfw-for-aws-discussions/terraform-ngfw-provider-failing-to-get-token-for/m-p/485235#M294</link>
      <description>&lt;P&gt;&lt;a href="https://live.paloaltonetworks.com/t5/user/viewprofilepage/user-id/46544"&gt;@gfreeman&lt;/a&gt;&amp;nbsp;The way in which resources get created "outside" terraform is not helping at all. I was able to create rulestack and firewall , yet when I try to create vpc endpoints on my side using vpc endpoint service for the NGFW, I get&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;LI-CODE lang="markup"&gt;│ Error: Error(1): Commit process unfinished.&lt;/LI-CODE&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;In the UI, everything looks ok&lt;/P&gt;
&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="SZanpure_0-1651766113261.png" style="width: 999px;"&gt;&lt;img src="https://live.paloaltonetworks.com/t5/image/serverpage/image-id/40874i75EF639684483233/image-size/large/is-moderation-mode/true?v=v2&amp;amp;px=999" role="button" title="SZanpure_0-1651766113261.png" alt="SZanpure_0-1651766113261.png" /&gt;&lt;/span&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="SZanpure_1-1651766146314.png" style="width: 999px;"&gt;&lt;img src="https://live.paloaltonetworks.com/t5/image/serverpage/image-id/40875i077035C0AA8C6919/image-size/large/is-moderation-mode/true?v=v2&amp;amp;px=999" role="button" title="SZanpure_1-1651766146314.png" alt="SZanpure_1-1651766146314.png" /&gt;&lt;/span&gt;&lt;/P&gt;
&lt;P&gt;Below is my terraform code&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;LI-CODE lang="markup"&gt;data "cloudngfwaws_ngfw" "palo-ngfw" {
  name = var.ngfw-name
}

data "aws_vpc_endpoint_service" "palo-ngfw-vpce-service" {
  service_name = data.cloudngfwaws_ngfw.palo-ngfw.endpoint_service_name
}

resource "aws_vpc_endpoint" "palo-ngfw-vpce-private-subnet-1" {
  vpc_id            = var.inspection-vpc-id
  service_name      = data.aws_vpc_endpoint_service.palo-ngfw-vpce-service.service_name
  vpc_endpoint_type = data.aws_vpc_endpoint_service.palo-ngfw-vpce-service.service_type

  subnet_ids          = [var.inspection-vpc-private-subnet-1-id]
  private_dns_enabled = false

  tags = {
    "Name" = "palo-ngfw-vpce-private-subnet-1"
  }
}

resource "aws_vpc_endpoint" "palo-ngfw-vpce-private-subnet-2" {
  vpc_id            = var.inspection-vpc-id
  service_name      = data.aws_vpc_endpoint_service.palo-ngfw-vpce-service.service_name
  vpc_endpoint_type = data.aws_vpc_endpoint_service.palo-ngfw-vpce-service.service_type

  subnet_ids          = [var.inspection-vpc-private-subnet-2-id]
  private_dns_enabled = false

  tags = {
    "Name" = "palo-ngfw-vpce-private-subnet-2"
  }
}

resource "aws_route" "inspection-rtb-tgw-subnet-1" {
  route_table_id         = var.inspection-vpc-tgw-rtb-subnet-1-id
  destination_cidr_block = "0.0.0.0/0"
  vpc_endpoint_id        = aws_vpc_endpoint.palo-ngfw-vpce-private-subnet-1.id
}

resource "aws_route" "inspection-rtb-tgw-subnet-2" {
  route_table_id         = var.inspection-vpc-tgw-rtb-subnet-2-id
  destination_cidr_block = "0.0.0.0/0"
  vpc_endpoint_id        = aws_vpc_endpoint.palo-ngfw-vpce-private-subnet-2.id
}&lt;/LI-CODE&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;What am I missing?&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Thu, 05 May 2022 15:57:24 GMT</pubDate>
      <guid>https://live.paloaltonetworks.com/t5/cloud-ngfw-for-aws-discussions/terraform-ngfw-provider-failing-to-get-token-for/m-p/485235#M294</guid>
      <dc:creator>SZanpure</dc:creator>
      <dc:date>2022-05-05T15:57:24Z</dc:date>
    </item>
    <item>
      <title>Re: Terraform NGFW provider failing to get token for CloudFirewallAdmin</title>
      <link>https://live.paloaltonetworks.com/t5/cloud-ngfw-for-aws-discussions/terraform-ngfw-provider-failing-to-get-token-for/m-p/485829#M295</link>
      <description>&lt;P&gt;This feels like TAC territory again to me...&amp;nbsp; You are in a situation where even using the GUI is not working / allowing you to recover.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;The AWS config I am honestly not very familiar with, so I won't be able to provide useful feedback on that part of it, sorry..&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;But to double back on what I was saying before:&amp;nbsp; you'll want to have 3 separate directories for your Terraform config:&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;dir1) All the code that defines both the rulestack and its contents (prefix lists, intelligent feeds, etc)&lt;/P&gt;
&lt;P&gt;dir2) &lt;CODE&gt;cloudngfwaws_commit_rulestack&lt;/CODE&gt; only&lt;/P&gt;
&lt;P&gt;dir3) All your &lt;CODE&gt;cloudngfwaws_ngfw&lt;/CODE&gt; instances&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;-- Edit --&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Forgot to mention:&amp;nbsp; and you only run the Dir3 terraform code if the commit shows as successfully committed from Dir2 (check using &lt;CODE&gt;terraform show&lt;/CODE&gt;).&amp;nbsp; Currently the &lt;CODE&gt;cloudngfwaws_commit_rulestack&lt;/CODE&gt; only returns an error if issuing the commit command fails, not if the commit itself fails.&amp;nbsp; It's possible that this will change before the provider exits beta, but this is the current implementation.&lt;/P&gt;</description>
      <pubDate>Mon, 09 May 2022 16:42:57 GMT</pubDate>
      <guid>https://live.paloaltonetworks.com/t5/cloud-ngfw-for-aws-discussions/terraform-ngfw-provider-failing-to-get-token-for/m-p/485829#M295</guid>
      <dc:creator>gfreeman</dc:creator>
      <dc:date>2022-05-09T16:42:57Z</dc:date>
    </item>
  </channel>
</rss>

