From f4d6d16c0bd18bbbab2755477de7e61e4eb641a7 Mon Sep 17 00:00:00 2001 From: Scott Ullrich Date: Mon, 6 Oct 2008 03:53:41 +0000 Subject: Add input validation routines --- packages/autoconfigbackup/autoconfigbackup.inc | 36 ++++++++++++++++++++++ packages/autoconfigbackup/autoconfigbackup.xml | 33 ++++++++++++-------- packages/autoconfigbackup/upload_config_filter.php | 1 - 3 files changed, 57 insertions(+), 13 deletions(-) create mode 100644 packages/autoconfigbackup/autoconfigbackup.inc (limited to 'packages/autoconfigbackup') diff --git a/packages/autoconfigbackup/autoconfigbackup.inc b/packages/autoconfigbackup/autoconfigbackup.inc new file mode 100644 index 00000000..c1fd11c4 --- /dev/null +++ b/packages/autoconfigbackup/autoconfigbackup.inc @@ -0,0 +1,36 @@ + $post['passwordagain']) + $input_errors[] = "Sorry, the entered passwords do not match."; +} + +?> \ No newline at end of file diff --git a/packages/autoconfigbackup/autoconfigbackup.xml b/packages/autoconfigbackup/autoconfigbackup.xml index 57d24f5d..1f3a8231 100644 --- a/packages/autoconfigbackup/autoconfigbackup.xml +++ b/packages/autoconfigbackup/autoconfigbackup.xml @@ -39,10 +39,11 @@ autoconfigbackup 1.0 Diagnostics: Auto Configuration Backup - Change + Change + /usr/local/pkg/autoconfigbackup.inc pkg_edit.php?xml=autoconfigbackup.xml&id=0 - autoconfigbackup Settings + AutoConfigBackup Set autoconfigbackup settings such as password and port.
Diagnostics
/pkg_edit.php?xml=autoconfigbackup.xml&id=0 @@ -57,9 +58,14 @@ 0755 http://www.pfsense.com/packages/config/autoconfigbackup/autoconfigbackup.php + + /usr/local/pkg/ + 0755 + http://www.pfsense.com/packages/config/autoconfigbackup/autoconfigbackup.inc + - autoconfigbackup Settings + Settings /pkg_edit.php?xml=autoconfigbackup.xml&id=0 @@ -70,28 +76,31 @@ - autoconfigbackup Subscription Username - input - Enter the username for the Automatic Configuration Backup Web GUI. Minimum 5 characters. - password + Subscription Username + username + Enter the username for the Automatic Configuration Backup Web GUI. Minimum 6 characters. + intput - autoconfigbackup Subscription Password + Subscription Password password - Enter the password for the Automatic Configuration Backup Web GUI. Minimum 5 characters. + Enter the password for the Automatic Configuration Backup Web GUI. Minimum 6 characters. password - autoconfigbackup Password AGAIN + Enter Password again passwordagain password - Encryption password + Encryption Password crypto_password password + + custom_php_validation_command($_POST, &$input_errors); + @@ -102,4 +111,4 @@ - + \ No newline at end of file diff --git a/packages/autoconfigbackup/upload_config_filter.php b/packages/autoconfigbackup/upload_config_filter.php index 876bc51f..2362d314 100644 --- a/packages/autoconfigbackup/upload_config_filter.php +++ b/packages/autoconfigbackup/upload_config_filter.php @@ -10,7 +10,6 @@ * */ - $last_backup_date = $config['system']['lastpfSbackup']; $last_config_change = $config['revision']['time']; -- cgit v1.2.3