NAME

PDK::Device::Paloalto - A module to interact with Palo Alto devices, including configuration retrieval and command execution.

SYNOPSIS

use PDK::Device::Paloalto;

my $device = PDK::Device::Paloalto->new(
  host     => '192.168.1.1',
  username => 'admin',
  password => 'password'
);

$device->login();
$device->getConfig();

DESCRIPTION

The PDK::Device::Paloalto module provides methods to interact with Palo Alto devices using CLI commands. It allows retrieving configurations, executing commands, and interacting with the device's CLI in an automated way.

ATTRIBUTES

prompt

The regular expression that matches the device's prompt, set by default to capture both active, passive, or suspended states.

METHODS

errCodes

Returns a list of regular expressions that match common error messages such as "Unknown command" or "Invalid syntax".

waitfor

Waits for a specific prompt while interacting with the device in an automated manner. It processes output until the expected prompt is matched.

getConfig

Retrieves the device's current configuration by executing a sequence of commands, including disabling the pager and setting the output format to the set format.

AUTHOR

WENWU YAN <968828@gmail.com>

LICENSE AND COPYRIGHT

Copyright (C) 2024 WENWU YAN

This program is free software; you can redistribute it and/or modify it under the terms of either: the GNU General Public License as published by the Free Software Foundation; or the Artistic License.