<?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 VS Code flags Venafi function names with warnings -FIX in Network Security Discussions</title>
    <link>https://live.paloaltonetworks.com/t5/network-security-discussions/vs-code-flags-venafi-function-names-with-warnings-fix/m-p/1419907#M605</link>
    <description>Just sharing something that has bugged me for a while.If you use VS Code to write your PowerShell drivers, then you have likely run into this issue. The built-in script analyzer highlights lots of really useful issues and has improved my code a lot, but it flags the Venafi required function name Perform-Action as a problem. Now theres nothing I can do about the Venafi implementation using the unapproved verb Perform but now all my adaptable log drivers are flagged with problems.The cmdlet Perform-Action uses an unapproved verb.If it was my code I would change the function name, but here my hands are tied.After much searching and researching, I found the way to disable just this warning without completely disabling this or other Script Analyzer functionality for my code. Inserting this line inside the function but before the Param( block will suppress this warning/problem.[Diagnostics.CodeAnalysis.SuppressMessage("PSUseApprovedVerbs", Scope="function", Target="Perform-Action" )]No more warnings / problems in my Adaptable Log driver..!I have updated my template with this so all my future drivers will not suffer from this issue and Im working through my handful of existing drivers as well.Venafi Team: It might be nice to include something like this line in the examples distributed with the product..</description>
    <pubDate>Thu, 18 Aug 2022 17:15:32 GMT</pubDate>
    <dc:creator>Christopher</dc:creator>
    <dc:date>2022-08-18T17:15:32Z</dc:date>
    <item>
      <title>VS Code flags Venafi function names with warnings -FIX</title>
      <link>https://live.paloaltonetworks.com/t5/network-security-discussions/vs-code-flags-venafi-function-names-with-warnings-fix/m-p/1419907#M605</link>
      <description>Just sharing something that has bugged me for a while.If you use VS Code to write your PowerShell drivers, then you have likely run into this issue. The built-in script analyzer highlights lots of really useful issues and has improved my code a lot, but it flags the Venafi required function name Perform-Action as a problem. Now theres nothing I can do about the Venafi implementation using the unapproved verb Perform but now all my adaptable log drivers are flagged with problems.The cmdlet Perform-Action uses an unapproved verb.If it was my code I would change the function name, but here my hands are tied.After much searching and researching, I found the way to disable just this warning without completely disabling this or other Script Analyzer functionality for my code. Inserting this line inside the function but before the Param( block will suppress this warning/problem.[Diagnostics.CodeAnalysis.SuppressMessage("PSUseApprovedVerbs", Scope="function", Target="Perform-Action" )]No more warnings / problems in my Adaptable Log driver..!I have updated my template with this so all my future drivers will not suffer from this issue and Im working through my handful of existing drivers as well.Venafi Team: It might be nice to include something like this line in the examples distributed with the product..</description>
      <pubDate>Thu, 18 Aug 2022 17:15:32 GMT</pubDate>
      <guid>https://live.paloaltonetworks.com/t5/network-security-discussions/vs-code-flags-venafi-function-names-with-warnings-fix/m-p/1419907#M605</guid>
      <dc:creator>Christopher</dc:creator>
      <dc:date>2022-08-18T17:15:32Z</dc:date>
    </item>
  </channel>
</rss>

