<?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 Tacacs_Enable with Python in API / CLI Discussion</title>
    <link>https://community.checkpoint.com/t5/API-CLI-Discussion/Tacacs-Enable-with-Python/m-p/129634#M6245</link>
    <description>&lt;P&gt;Hey everyone, I am trying to work on a python script that logs onto a firewall, moves into TACP-15 and enters the relevant password.&amp;nbsp; After which it runs a command.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Problem is the script is getting stuck at the password prompt after running: tacacs_enable TACP-15.&lt;/P&gt;&lt;P&gt;I've tried adding \r to no avail.&amp;nbsp; Has anyone managed this?&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Relevant part of the script below:&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;PRE&gt;&lt;SPAN&gt;# Then send the command and print the output&lt;BR /&gt;&lt;/SPAN&gt;&lt;SPAN&gt;&lt;BR /&gt;&lt;/SPAN&gt;output = net_connect.send_command(&lt;SPAN&gt;'lock database override'&lt;/SPAN&gt;)&lt;BR /&gt;&lt;SPAN&gt;print&lt;/SPAN&gt;(output)&lt;BR /&gt;&lt;BR /&gt;output = net_connect.send_command(&lt;SPAN&gt;'tacacs_enable TACP-15'&lt;/SPAN&gt;)&lt;BR /&gt;&lt;SPAN&gt;print&lt;/SPAN&gt;(output)&lt;BR /&gt;&lt;BR /&gt;output = net_connect.send_command(expert_password)&lt;BR /&gt;&lt;SPAN&gt;print&lt;/SPAN&gt;(output)&lt;BR /&gt;&lt;BR /&gt;output = net_connect.send_command(&lt;SPAN&gt;'show route'&lt;/SPAN&gt;)&lt;BR /&gt;&lt;SPAN&gt;print&lt;/SPAN&gt;(output)&lt;/PRE&gt;</description>
    <pubDate>Fri, 17 Sep 2021 10:20:45 GMT</pubDate>
    <dc:creator>stevenhunt77</dc:creator>
    <dc:date>2021-09-17T10:20:45Z</dc:date>
    <item>
      <title>Tacacs_Enable with Python</title>
      <link>https://community.checkpoint.com/t5/API-CLI-Discussion/Tacacs-Enable-with-Python/m-p/129634#M6245</link>
      <description>&lt;P&gt;Hey everyone, I am trying to work on a python script that logs onto a firewall, moves into TACP-15 and enters the relevant password.&amp;nbsp; After which it runs a command.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Problem is the script is getting stuck at the password prompt after running: tacacs_enable TACP-15.&lt;/P&gt;&lt;P&gt;I've tried adding \r to no avail.&amp;nbsp; Has anyone managed this?&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Relevant part of the script below:&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;PRE&gt;&lt;SPAN&gt;# Then send the command and print the output&lt;BR /&gt;&lt;/SPAN&gt;&lt;SPAN&gt;&lt;BR /&gt;&lt;/SPAN&gt;output = net_connect.send_command(&lt;SPAN&gt;'lock database override'&lt;/SPAN&gt;)&lt;BR /&gt;&lt;SPAN&gt;print&lt;/SPAN&gt;(output)&lt;BR /&gt;&lt;BR /&gt;output = net_connect.send_command(&lt;SPAN&gt;'tacacs_enable TACP-15'&lt;/SPAN&gt;)&lt;BR /&gt;&lt;SPAN&gt;print&lt;/SPAN&gt;(output)&lt;BR /&gt;&lt;BR /&gt;output = net_connect.send_command(expert_password)&lt;BR /&gt;&lt;SPAN&gt;print&lt;/SPAN&gt;(output)&lt;BR /&gt;&lt;BR /&gt;output = net_connect.send_command(&lt;SPAN&gt;'show route'&lt;/SPAN&gt;)&lt;BR /&gt;&lt;SPAN&gt;print&lt;/SPAN&gt;(output)&lt;/PRE&gt;</description>
      <pubDate>Fri, 17 Sep 2021 10:20:45 GMT</pubDate>
      <guid>https://community.checkpoint.com/t5/API-CLI-Discussion/Tacacs-Enable-with-Python/m-p/129634#M6245</guid>
      <dc:creator>stevenhunt77</dc:creator>
      <dc:date>2021-09-17T10:20:45Z</dc:date>
    </item>
    <item>
      <title>Re: Tacacs_Enable with Python</title>
      <link>https://community.checkpoint.com/t5/API-CLI-Discussion/Tacacs-Enable-with-Python/m-p/129642#M6246</link>
      <description>&lt;P&gt;Why don't you use the GAIA API instead in combination with Python (requests module)?&lt;/P&gt;&lt;P&gt;For example:&lt;/P&gt;&lt;P&gt;POST &lt;A target="_blank" rel="noopener"&gt;https://&amp;lt;server-ip&amp;gt;:&amp;lt;port&amp;gt;/gaia_api/v1.6/show-routes&lt;/A&gt;&lt;/P&gt;&lt;P&gt;Documentation:&lt;/P&gt;&lt;P&gt;&lt;A href="https://sc1.checkpoint.com/documents/latest/GaiaAPIs/#web/show-routes~v1.6%20" target="_blank" rel="noopener"&gt;https://sc1.checkpoint.com/documents/latest/GaiaAPIs/#web/show-routes~v1.6%20&lt;/A&gt;&lt;/P&gt;</description>
      <pubDate>Fri, 17 Sep 2021 17:18:52 GMT</pubDate>
      <guid>https://community.checkpoint.com/t5/API-CLI-Discussion/Tacacs-Enable-with-Python/m-p/129642#M6246</guid>
      <dc:creator>Andre_K</dc:creator>
      <dc:date>2021-09-17T17:18:52Z</dc:date>
    </item>
    <item>
      <title>Re: Tacacs_Enable with Python</title>
      <link>https://community.checkpoint.com/t5/API-CLI-Discussion/Tacacs-Enable-with-Python/m-p/129643#M6247</link>
      <description>&lt;P&gt;Hey, the show route command is just an example.&amp;nbsp; Really we would want to be doing various configuration commands such as configuring SNMP or tweaking RBA roles etc.&lt;/P&gt;</description>
      <pubDate>Fri, 17 Sep 2021 11:23:34 GMT</pubDate>
      <guid>https://community.checkpoint.com/t5/API-CLI-Discussion/Tacacs-Enable-with-Python/m-p/129643#M6247</guid>
      <dc:creator>stevenhunt77</dc:creator>
      <dc:date>2021-09-17T11:23:34Z</dc:date>
    </item>
    <item>
      <title>Re: Tacacs_Enable with Python</title>
      <link>https://community.checkpoint.com/t5/API-CLI-Discussion/Tacacs-Enable-with-Python/m-p/129661#M6250</link>
      <description>&lt;P&gt;You can also use&amp;nbsp;&lt;EM&gt;run-script&lt;/EM&gt; for running commands either through the Gaia API or the Management API.&lt;/P&gt;
&lt;P&gt;&lt;A href="https://sc1.checkpoint.com/documents/latest/GaiaAPIs/#web/run-script~v1.6%20" target="_blank"&gt;https://sc1.checkpoint.com/documents/latest/GaiaAPIs/#web/run-script~v1.6%20&lt;/A&gt;&lt;BR /&gt;&lt;A href="https://sc1.checkpoint.com/documents/latest/APIs/#cli/run-script~v1.6%20" target="_blank"&gt;https://sc1.checkpoint.com/documents/latest/APIs/#cli/run-script~v1.6%20&lt;/A&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;/P&gt;</description>
      <pubDate>Fri, 17 Sep 2021 14:39:06 GMT</pubDate>
      <guid>https://community.checkpoint.com/t5/API-CLI-Discussion/Tacacs-Enable-with-Python/m-p/129661#M6250</guid>
      <dc:creator>Art_Zalenekas</dc:creator>
      <dc:date>2021-09-17T14:39:06Z</dc:date>
    </item>
  </channel>
</rss>

