diff --git a/wp-content/plugins/wp-security-scan/index.php b/wp-content/plugins/wp-security-scan/index.php deleted file mode 100644 index 28ff286a..00000000 --- a/wp-content/plugins/wp-security-scan/index.php +++ /dev/null @@ -1,104 +0,0 @@ -'.__('Settings',WpsSettings::TEXT_DOMAIN).''), $links);} else { return $links; } } -add_filter("plugin_action_links_".plugin_basename(__FILE__), 'wssCustomLinks' ); - -//#! register tasks -if($wpsCanRun) -{ -// register cron job - WsdScheduler::registerCronTask('wssPlugin_WpScanCheckState', array('WsdWpScanner','checkWpScan'), '1m'); - -// override - scheduled task - WsdScheduler::registerCronTask('wps_check_user_admin', array('WsdCheck','adminUsername'), '8h'); - WsdScheduler::registerCronTask('wps_check_admin_install_file', array('WsdCheck','check_adminInstallFile'), 'hourly'); - WsdScheduler::registerCronTask('wps_check_admin_upgrade_file', array('WsdCheck','check_adminUpgradeFile'), 'hourly'); - -// scheduled task - hourly cleanup of events in live traffic - WsdScheduler::registerCronTask('wps_cleanup_live_traffic', array('WsdLiveTraffic','clearEvents'), 'hourly'); - -// stacked - WsdScheduler::registerTask(array('WsdWatch','userPasswordUpdate')); - -// #! run fixes. Only those checked by the user will run (@see: settings page) - wpsRunFixes(); - -//#! run checks. - add_action('init', array('WsdCheck','check_tablePrefix')); - add_action('init', array('WsdCheck','check_currentVersion')); - add_action('init', array('WsdCheck','check_files')); -} -//#! End index.php \ No newline at end of file diff --git a/wp-content/plugins/wp-security-scan/readme.txt b/wp-content/plugins/wp-security-scan/readme.txt deleted file mode 100644 index b623889e..00000000 --- a/wp-content/plugins/wp-security-scan/readme.txt +++ /dev/null @@ -1,263 +0,0 @@ -=== Acunetix WP Security === -Contributors: Acunetix -Author: Acunetix -Tags: security, securityscan, chmod, permissions, admin, administration, authentication, database, dashboard, post, notification, password, plugin, posts, -plugins, private, protection, tracking, wordpress -Requires at least: 3.0 -Tested up to: 4.2 -Stable tag: trunk -License: GPLv2 or later -License URI: http://www.gnu.org/licenses/gpl-2.0.html - -Scans your WordPress installation for security vulnerabilities. - -== Description == -Acunetix WP Security plugin is a free and comprehensive security tool that helps you secure your WordPress -installation and suggests corrective measures for: securing file permissions, security of the database, version hiding, -WordPress admin protection and lots more. - -Acunetix WP Security checks your WordPress website/blog for security vulnerabilities and suggests corrective actions such as: - -1. Passwords -2. File permissions -3. Database security -4. Version hiding -5. WordPress admin protection/security -6. Removes WP Generator META tag from core code - -= Requirements = - -* WordPress version 3.0 and higher -* PHP5 (tested with PHP Interpreter >= 5.2.9) - - -= Key security features: = - -* MultiSite ready -* Easy backup of WordPress database for disaster recovery -* Removal of error-information on login-page -* Addition of index.php to the wp-content, wp-content/plugins, wp-content/themes and wp-content/uploads directories to prevent directory listings -* Removal of wp-version, except in admin-area -* Removal of Really Simple Discovery meta tag -* Removal of Windows Live Writer meta tag -* Removal of core update information for non-admins -* Removal of plugin-update information for non-admins -* Removal of theme-update information for non-admins (only WP 2.8 and higher) -* Hiding of wp-version in backend-dashboard for non-admins -* Removal of version in URLs from scripts and stylesheets only on frontend -* Reporting of security overview after WordPress blog is scanned -* Reporting of file permissions following security checks -* Live traffic tool to monitor your website activity in real time -* Integrated tool to change the database prefix -* Disabling of database error reporting (if enabled) -* Disabling of PHP error reporting - -For more information on the Acunetix WP Security plug-in and other WordPress security news, visit the -Acunetix Blog and join -our Facebook page. Post any questions or feedback -on the Acunetix WP Security plug-in forum. - - - -== Installation == - -* Make a backup of your current installation -* Unpack the downloaded package -* Upload the extracted files to the /wp-content/plugins/ directory -* Activate the plugin through the 'Plugins' menu in WordPress - -If you encounter any bugs, or have comments or suggestions, please post them on the -Acunetix WP Security plug-in forum. - -For more information on the Acunetix WP Security plug-in and other WordPress security news, visit the -Acunetix Blog and join -our Facebook page. Post any questions or feedback -on the Acunetix WP Security plug-in forum. - - -== Frequently Asked Questions == - -= Can I deactivate Acunetix WP Security once I've run it once? = - -No. Acunetix WP Security needs to be left activated to work. Version hiding, -turning off DB errors, removing WP ID META tag from HTML output, and other -functionality will cease if you deactivate the plugin. - -= How do I change the file permissions on my WordPress installation? = - -From the Linux command line (for advanced users): - chmod xxx filename.ext - (replace xxx with with the permissions settings for the file or folder). - -From your FTP client: - Most FTP clients, such as FileZilla, etc, allow for changing file -permissions. Please consult your client's documentation for your specific -directions. - -= I cannot activate the plugin for individual sites in MultiSite? = -No, the Acunetix WP Security plugin when running in a MultiSite installation can only be network activated. It cannot be -activated per individual sites. All its features are related to the whole network and activating it per individual sites -would be pointless. - -For more information, please visit http://codex.wordpress.org/Changing_File_Permissions - -= Why do I need to hide my version of WordPress? = - -Many attackers and automated tools will try and determine software versions -before launching exploit code. Removing your WordPress blog version may -discourage some attackers and certainly will mitigate virus and malware programs -that rely on software versions. - -For more information on the Acunetix WP Security plug-in and other WordPress security news, visit the -Acunetix Blog and join -our Facebook page. Post any questions or feedback -on the Acunetix WP Security plug-in forum. - - -== Screenshots == - -1. The File Scan Report -2. The Settings page, displaying all configurable options -3. The Live Traffic page -4. The new Dashboard page -5. The new Scan Page - -== WordPress Security == - -Security Scanner: - -1. Scans WordPress installation for file/directory permissions vulnerabilites -2. Recommends corrective actions -3. Scans for general security vulnerabilities - - -== Other Notes == -= License = -Good news, this plugin is free for everyone! Since it's released under the GPL, you can use it free of charge on your personal or commercial blog. - -For more information on the Acunetix WP Security plug-in and other WordPress security news, visit the -Acunetix Blog and join -our Facebook page. Post any questions or feedback -on the Acunetix WP Security plug-in forum. - - -== Changelog == - -= 4.0.5 = -* Added CSRF prevention mechanism - - -= 4.0.4 = -* Add support for WordPress 4.0 - - -= 4.0.3 = -* New Feature: Added support for MultiSite -* New Feature: Added the WP file scan tool for checking the core WP files for modification date -* New Feature: Added geo location to Live traffic tool -* New Feature: Added ip lookup to Live Traffic tool -* New Feature: Added support for deleting the database backup files -* New Feature: Added the link to the plugin's settings page in the plugins page -* New Feature: Live traffic tool can now be enabled/disabled from the settings page -* New Alerts: Two new security checks were added for the install.php and upgrade.php files from wp-admin directory -* Update: Improved the Live Traffic code and functionality -* Update: Fixed the broken path to wp-config.php file -* Update: Improved the Dashboard's UI -* Update: When running in a MultiSite installation, the plugin can only be "Network activated" -* Fixed bug when the ReflectionClass is not available. -* Fixed various bugs reported in the forums - - -= 4.0.2 = -* New Feature: Added support for MultiSite -* New Feature: Added the WP file scan tool for checking the core WP files for modification date -* New Feature: Added geo location to Live traffic tool -* New Feature: Added ip lookup to Live Traffic tool -* New Feature: Added support for deleting the database backup files -* New Feature: Added the link to the plugin's settings page in the plugins page -* New Feature: Live traffic tool can now be enabled/disabled from the settings page -* New Alerts: Two new security checks were added for the install.php and upgrade.php files from wp-admin directory -* Update: Improved the Live Traffic code and functionality -* Update: Fixed the broken path to wp-config.php file -* Update: Improved the Dashboard's UI -* Update: When running in a MultiSite installation, the plugin can only be "Network activated" -* Fixed bug when the ReflectionClass is not available. -* Fixed various bugs reported in the forums - - -= 4.0.1 = -* Fixed the LiveTraffic bug - - -= 4.0.0 = -* Complete core update -* Added live traffic functionality -* Added check for the wp-config.php file one level above if not found in the install directory -* Fixed broken functionalities -* Security settings are now configurable - - -= 3.1.0 = -* Removed the registration requirement - -= v3.0.9 = -* New feature: Added tooltips to the most important sections of the System Information box -* Update: Added 'nonce' fields to forms where needed (thanks to julio from boiteaweb.fr) -* Update: Updated the deprecated function call get_bloginfo('siteurl') to get_bloginfo('url') -* Update: Updated paths to external resources such as javascript and css files for ssl compatibility -* Update: Updated validation for plug-in form fields (email address, user name, target id, etc.) -* Update: Enhanced the input validation for the Change Database Prefix tool -* Update: Plugin settings are now accessible only by WordPress administrators -* Update: Improved user-rights retrieval in the WordPress database - - -= v3.0.8 = -* New feature: Option to open / close WebsiteDefender dashboard widget -* Update: More help resource links -* Update: Internal code updates - -= v3.0.7 = -* BugFix: The bug reported about ALTER rights retrieval has been addressed -* Update: Code cleanup -* Update: Minor internal updates - -= v3.0.6 = -* Feature: The WebsiteDefender RSS widget added to the admin dashboard -* Update: The plug-in has been made compatible with Secure WP and WebsiteDefender WordPress Security -* Update: The plug-in can be safe used in a Multi User WP environment -* Bugfix: Fixed the bug related to the database ALTER rights retrieval -* BugFix: Fixed the version information script - -= v3.0.5 (07/20/2011) = -* Bugfix: Updated the links to websitedefender.com - -= v3.0.4 (07/20/2011) = -* Update: the plug-in has been made compatible with Secure WP plug-in - -= v3.0.3 (07/14/2011) = -* Bugfix: Fixed the code error in the change database prefix feature -* Update: More code cleanup - -= v3.0.2 (07/11/2011) = -* Feature: Enabled automatic database table prefix rename feature -* Feature: Database backup functionality used in databse renaming tables -* Feature: Included more documentation / links for a number of features -* Feature: Prevent blog owner from changing table prefix if the wp-config.php file is not writable -* Update: Updated several error messages text (user friendly) -* Update: major code cleanup -* Bugfix: Fixed a number of bugs in the database tables rename utility - -= v3.0.1 (03/24/2011) = -* Regression: Temporarily disabled database change feature -* Fixed: Resolved conflict with plugins using the reCAPTCHA library -* Bugfix: Fixed CSS image background not showing corectly - -= v3.0.0 (03/22/2011) = -* Feature: Release new stable version -* Feature: Rebranding of the plugin -* Feature: Integrated WebsiteDefender.com registration in Settings - -For more information on the Acunetix WP Security plug-in and other WordPress security news, visit the -Acunetix Blog and join -our Facebook page. Post any questions or feedback -on the Acunetix WP Security plug-in forum. diff --git a/wp-content/plugins/wp-security-scan/res/backups/index.php b/wp-content/plugins/wp-security-scan/res/backups/index.php deleted file mode 100644 index fe0ab8ea..00000000 --- a/wp-content/plugins/wp-security-scan/res/backups/index.php +++ /dev/null @@ -1 +0,0 @@ - li, -ol.inline > li { - display: inline-block; - *display: inline; - padding-right: 5px; - padding-left: 5px; - *zoom: 1; -} - -dl { - margin-bottom: 20px; -} - -dt, -dd { - line-height: 20px; -} - -dt { - font-weight: bold; -} - -dd { - margin-left: 10px; -} - -.dl-horizontal { - *zoom: 1; -} - -.dl-horizontal:before, -.dl-horizontal:after { - display: table; - line-height: 0; - content: ""; -} - -.dl-horizontal:after { - clear: both; -} - -.dl-horizontal dt { - float: left; - width: 160px; - overflow: hidden; - clear: left; - text-align: right; - text-overflow: ellipsis; - white-space: nowrap; -} - -.dl-horizontal dd { - margin-left: 180px; -} - -hr { - margin: 20px 0; - border: 0; - border-top: 1px solid #eeeeee; - border-bottom: 1px solid #ffffff; -} - -abbr[title], -abbr[data-original-title] { - cursor: help; - border-bottom: 1px dotted #999999; -} - -abbr.initialism { - font-size: 90%; - text-transform: uppercase; -} - -blockquote { - padding: 0 0 0 15px; - margin: 0 0 20px; - border-left: 5px solid #eeeeee; -} - -blockquote p { - margin-bottom: 0; - font-size: 17.5px; - font-weight: 300; - line-height: 1.25; -} - -blockquote small { - display: block; - line-height: 20px; - color: #999999; -} - -blockquote small:before { - content: '\2014 \00A0'; -} - -blockquote.pull-right { - float: right; - padding-right: 15px; - padding-left: 0; - border-right: 5px solid #eeeeee; - border-left: 0; -} - -blockquote.pull-right p, -blockquote.pull-right small { - text-align: right; -} - -blockquote.pull-right small:before { - content: ''; -} - -blockquote.pull-right small:after { - content: '\00A0 \2014'; -} - -q:before, -q:after, -blockquote:before, -blockquote:after { - content: ""; -} - -address { - display: block; - margin-bottom: 20px; - font-style: normal; - line-height: 20px; -} - -code, -pre { - padding: 0 3px 2px; - font-family: Monaco, Menlo, Consolas, "Courier New", monospace; - font-size: 12px; - color: #333333; - -webkit-border-radius: 3px; - -moz-border-radius: 3px; - border-radius: 3px; -} - -code { - padding: 2px 4px; - color: #d14; - white-space: nowrap; - background-color: #f7f7f9; - border: 1px solid #e1e1e8; -} - -pre { - display: block; - padding: 9.5px; - margin: 0 0 10px; - font-size: 13px; - line-height: 20px; - word-break: break-all; - word-wrap: break-word; - white-space: pre; - white-space: pre-wrap; - background-color: #f5f5f5; - border: 1px solid #ccc; - border: 1px solid rgba(0, 0, 0, 0.15); - -webkit-border-radius: 4px; - -moz-border-radius: 4px; - border-radius: 4px; -} - -pre.prettyprint { - margin-bottom: 20px; -} - -pre code { - padding: 0; - color: inherit; - white-space: pre; - white-space: pre-wrap; - background-color: transparent; - border: 0; -} - -.pre-scrollable { - max-height: 340px; - overflow-y: scroll; -} - -form { - margin: 0 0 20px; -} - -fieldset { - padding: 0; - margin: 0; - border: 0; -} - -legend { - display: block; - width: 100%; - padding: 0; - margin-bottom: 20px; - font-size: 21px; - line-height: 40px; - color: #333333; - border: 0; - border-bottom: 1px solid #e5e5e5; -} - -legend small { - font-size: 15px; - color: #999999; -} - -label, -input, -button, -select, -textarea { - font-size: 14px; - font-weight: normal; - line-height: 20px; -} - -input, -button, -select, -textarea { - font-family: "Helvetica Neue", Helvetica, Arial, sans-serif; -} - -label { - display: block; - margin-bottom: 5px; -} - -select, -textarea, -input[type="text"], -input[type="password"], -input[type="datetime"], -input[type="datetime-local"], -input[type="date"], -input[type="month"], -input[type="time"], -input[type="week"], -input[type="number"], -input[type="email"], -input[type="url"], -input[type="search"], -input[type="tel"], -input[type="color"], -.uneditable-input { - display: inline-block; - height: 20px; - padding: 4px 6px; - margin-bottom: 10px; - font-size: 14px; - line-height: 20px; - color: #555555; - vertical-align: middle; - -webkit-border-radius: 4px; - -moz-border-radius: 4px; - border-radius: 4px; -} - -input, -textarea, -.uneditable-input { - width: 206px; -} - -textarea { - height: auto; -} - -textarea, -input[type="text"], -input[type="password"], -input[type="datetime"], -input[type="datetime-local"], -input[type="date"], -input[type="month"], -input[type="time"], -input[type="week"], -input[type="number"], -input[type="email"], -input[type="url"], -input[type="search"], -input[type="tel"], -input[type="color"], -.uneditable-input { - background-color: #ffffff; - border: 1px solid #cccccc; - -webkit-box-shadow: inset 0 1px 1px rgba(0, 0, 0, 0.075); - -moz-box-shadow: inset 0 1px 1px rgba(0, 0, 0, 0.075); - box-shadow: inset 0 1px 1px rgba(0, 0, 0, 0.075); - -webkit-transition: border linear 0.2s, box-shadow linear 0.2s; - -moz-transition: border linear 0.2s, box-shadow linear 0.2s; - -o-transition: border linear 0.2s, box-shadow linear 0.2s; - transition: border linear 0.2s, box-shadow linear 0.2s; -} - -textarea:focus, -input[type="text"]:focus, -input[type="password"]:focus, -input[type="datetime"]:focus, -input[type="datetime-local"]:focus, -input[type="date"]:focus, -input[type="month"]:focus, -input[type="time"]:focus, -input[type="week"]:focus, -input[type="number"]:focus, -input[type="email"]:focus, -input[type="url"]:focus, -input[type="search"]:focus, -input[type="tel"]:focus, -input[type="color"]:focus, -.uneditable-input:focus { - border-color: rgba(82, 168, 236, 0.8); - outline: 0; - outline: thin dotted \9; - /* IE6-9 */ - - -webkit-box-shadow: inset 0 1px 1px rgba(0, 0, 0, 0.075), 0 0 8px rgba(82, 168, 236, 0.6); - -moz-box-shadow: inset 0 1px 1px rgba(0, 0, 0, 0.075), 0 0 8px rgba(82, 168, 236, 0.6); - box-shadow: inset 0 1px 1px rgba(0, 0, 0, 0.075), 0 0 8px rgba(82, 168, 236, 0.6); -} - -input[type="radio"], -input[type="checkbox"] { - margin: 4px 0 0; - margin-top: 1px \9; - *margin-top: 0; - line-height: normal; -} - -input[type="file"], -input[type="image"], -input[type="submit"], -input[type="reset"], -input[type="button"], -input[type="radio"], -input[type="checkbox"] { - width: auto; -} - -select, -input[type="file"] { - height: 30px; - /* In IE7, the height of the select element cannot be changed by height, only font-size */ - - *margin-top: 4px; - /* For IE7, add top margin to align select with labels */ - - line-height: 30px; -} - -select { - width: 220px; - background-color: #ffffff; - border: 1px solid #cccccc; -} - -select[multiple], -select[size] { - height: auto; -} - -select:focus, -input[type="file"]:focus, -input[type="radio"]:focus, -input[type="checkbox"]:focus { - outline: thin dotted #333; - outline: 5px auto -webkit-focus-ring-color; - outline-offset: -2px; -} - -.uneditable-input, -.uneditable-textarea { - color: #999999; - cursor: not-allowed; - background-color: #fcfcfc; - border-color: #cccccc; - -webkit-box-shadow: inset 0 1px 2px rgba(0, 0, 0, 0.025); - -moz-box-shadow: inset 0 1px 2px rgba(0, 0, 0, 0.025); - box-shadow: inset 0 1px 2px rgba(0, 0, 0, 0.025); -} - -.uneditable-input { - overflow: hidden; - white-space: nowrap; -} - -.uneditable-textarea { - width: auto; - height: auto; -} - -input:-moz-placeholder, -textarea:-moz-placeholder { - color: #999999; -} - -input:-ms-input-placeholder, -textarea:-ms-input-placeholder { - color: #999999; -} - -input::-webkit-input-placeholder, -textarea::-webkit-input-placeholder { - color: #999999; -} - -.radio, -.checkbox { - min-height: 20px; - padding-left: 20px; -} - -.radio input[type="radio"], -.checkbox input[type="checkbox"] { - float: left; - margin-left: -20px; -} - -.controls > .radio:first-child, -.controls > .checkbox:first-child { - padding-top: 5px; -} - -.radio.inline, -.checkbox.inline { - display: inline-block; - padding-top: 5px; - margin-bottom: 0; - vertical-align: middle; -} - -.radio.inline + .radio.inline, -.checkbox.inline + .checkbox.inline { - margin-left: 10px; -} - -.input-mini { - width: 60px; -} - -.input-small { - width: 90px; -} - -.input-medium { - width: 150px; -} - -.input-large { - width: 210px; -} - -.input-xlarge { - width: 270px; -} - -.input-xxlarge { - width: 530px; -} - -input[class*="span"], -select[class*="span"], -textarea[class*="span"], -.uneditable-input[class*="span"], -.row-fluid input[class*="span"], -.row-fluid select[class*="span"], -.row-fluid textarea[class*="span"], -.row-fluid .uneditable-input[class*="span"] { - float: none; - margin-left: 0; -} - -.input-append input[class*="span"], -.input-append .uneditable-input[class*="span"], -.input-prepend input[class*="span"], -.input-prepend .uneditable-input[class*="span"], -.row-fluid input[class*="span"], -.row-fluid select[class*="span"], -.row-fluid textarea[class*="span"], -.row-fluid .uneditable-input[class*="span"], -.row-fluid .input-prepend [class*="span"], -.row-fluid .input-append [class*="span"] { - display: inline-block; -} - -input, -textarea, -.uneditable-input { - margin-left: 0; -} - -.controls-row [class*="span"] + [class*="span"] { - margin-left: 20px; -} - -input.span12, -textarea.span12, -.uneditable-input.span12 { - width: 926px; -} - -input.span11, -textarea.span11, -.uneditable-input.span11 { - width: 846px; -} - -input.span10, -textarea.span10, -.uneditable-input.span10 { - width: 766px; -} - -input.span9, -textarea.span9, -.uneditable-input.span9 { - width: 686px; -} - -input.span8, -textarea.span8, -.uneditable-input.span8 { - width: 606px; -} - -input.span7, -textarea.span7, -.uneditable-input.span7 { - width: 526px; -} - -input.span6, -textarea.span6, -.uneditable-input.span6 { - width: 446px; -} - -input.span5, -textarea.span5, -.uneditable-input.span5 { - width: 366px; -} - -input.span4, -textarea.span4, -.uneditable-input.span4 { - width: 286px; -} - -input.span3, -textarea.span3, -.uneditable-input.span3 { - width: 206px; -} - -input.span2, -textarea.span2, -.uneditable-input.span2 { - width: 126px; -} - -input.span1, -textarea.span1, -.uneditable-input.span1 { - width: 46px; -} - -.controls-row { - *zoom: 1; -} - -.controls-row:before, -.controls-row:after { - display: table; - line-height: 0; - content: ""; -} - -.controls-row:after { - clear: both; -} - -.controls-row [class*="span"], -.row-fluid .controls-row [class*="span"] { - float: left; -} - -.controls-row .checkbox[class*="span"], -.controls-row .radio[class*="span"] { - padding-top: 5px; -} - -input[disabled], -select[disabled], -textarea[disabled], -input[readonly], -select[readonly], -textarea[readonly] { - cursor: not-allowed; - background-color: #eeeeee; -} - -input[type="radio"][disabled], -input[type="checkbox"][disabled], -input[type="radio"][readonly], -input[type="checkbox"][readonly] { - background-color: transparent; -} - -.control-group.warning .control-label, -.control-group.warning .help-block, -.control-group.warning .help-inline { - color: #c09853; -} - -.control-group.warning .checkbox, -.control-group.warning .radio, -.control-group.warning input, -.control-group.warning select, -.control-group.warning textarea { - color: #c09853; -} - -.control-group.warning input, -.control-group.warning select, -.control-group.warning textarea { - border-color: #c09853; - -webkit-box-shadow: inset 0 1px 1px rgba(0, 0, 0, 0.075); - -moz-box-shadow: inset 0 1px 1px rgba(0, 0, 0, 0.075); - box-shadow: inset 0 1px 1px rgba(0, 0, 0, 0.075); -} - -.control-group.warning input:focus, -.control-group.warning select:focus, -.control-group.warning textarea:focus { - border-color: #a47e3c; - -webkit-box-shadow: inset 0 1px 1px rgba(0, 0, 0, 0.075), 0 0 6px #dbc59e; - -moz-box-shadow: inset 0 1px 1px rgba(0, 0, 0, 0.075), 0 0 6px #dbc59e; - box-shadow: inset 0 1px 1px rgba(0, 0, 0, 0.075), 0 0 6px #dbc59e; -} - -.control-group.warning .input-prepend .add-on, -.control-group.warning .input-append .add-on { - color: #c09853; - background-color: #fcf8e3; - border-color: #c09853; -} - -.control-group.error .control-label, -.control-group.error .help-block, -.control-group.error .help-inline { - color: #b94a48; -} - -.control-group.error .checkbox, -.control-group.error .radio, -.control-group.error input, -.control-group.error select, -.control-group.error textarea { - color: #b94a48; -} - -.control-group.error input, -.control-group.error select, -.control-group.error textarea { - border-color: #b94a48; - -webkit-box-shadow: inset 0 1px 1px rgba(0, 0, 0, 0.075); - -moz-box-shadow: inset 0 1px 1px rgba(0, 0, 0, 0.075); - box-shadow: inset 0 1px 1px rgba(0, 0, 0, 0.075); -} - -.control-group.error input:focus, -.control-group.error select:focus, -.control-group.error textarea:focus { - border-color: #953b39; - -webkit-box-shadow: inset 0 1px 1px rgba(0, 0, 0, 0.075), 0 0 6px #d59392; - -moz-box-shadow: inset 0 1px 1px rgba(0, 0, 0, 0.075), 0 0 6px #d59392; - box-shadow: inset 0 1px 1px rgba(0, 0, 0, 0.075), 0 0 6px #d59392; -} - -.control-group.error .input-prepend .add-on, -.control-group.error .input-append .add-on { - color: #b94a48; - background-color: #f2dede; - border-color: #b94a48; -} - -.control-group.success .control-label, -.control-group.success .help-block, -.control-group.success .help-inline { - color: #468847; -} - -.control-group.success .checkbox, -.control-group.success .radio, -.control-group.success input, -.control-group.success select, -.control-group.success textarea { - color: #468847; -} - -.control-group.success input, -.control-group.success select, -.control-group.success textarea { - border-color: #468847; - -webkit-box-shadow: inset 0 1px 1px rgba(0, 0, 0, 0.075); - -moz-box-shadow: inset 0 1px 1px rgba(0, 0, 0, 0.075); - box-shadow: inset 0 1px 1px rgba(0, 0, 0, 0.075); -} - -.control-group.success input:focus, -.control-group.success select:focus, -.control-group.success textarea:focus { - border-color: #356635; - -webkit-box-shadow: inset 0 1px 1px rgba(0, 0, 0, 0.075), 0 0 6px #7aba7b; - -moz-box-shadow: inset 0 1px 1px rgba(0, 0, 0, 0.075), 0 0 6px #7aba7b; - box-shadow: inset 0 1px 1px rgba(0, 0, 0, 0.075), 0 0 6px #7aba7b; -} - -.control-group.success .input-prepend .add-on, -.control-group.success .input-append .add-on { - color: #468847; - background-color: #dff0d8; - border-color: #468847; -} - -.control-group.info .control-label, -.control-group.info .help-block, -.control-group.info .help-inline { - color: #3a87ad; -} - -.control-group.info .checkbox, -.control-group.info .radio, -.control-group.info input, -.control-group.info select, -.control-group.info textarea { - color: #3a87ad; -} - -.control-group.info input, -.control-group.info select, -.control-group.info textarea { - border-color: #3a87ad; - -webkit-box-shadow: inset 0 1px 1px rgba(0, 0, 0, 0.075); - -moz-box-shadow: inset 0 1px 1px rgba(0, 0, 0, 0.075); - box-shadow: inset 0 1px 1px rgba(0, 0, 0, 0.075); -} - -.control-group.info input:focus, -.control-group.info select:focus, -.control-group.info textarea:focus { - border-color: #2d6987; - -webkit-box-shadow: inset 0 1px 1px rgba(0, 0, 0, 0.075), 0 0 6px #7ab5d3; - -moz-box-shadow: inset 0 1px 1px rgba(0, 0, 0, 0.075), 0 0 6px #7ab5d3; - box-shadow: inset 0 1px 1px rgba(0, 0, 0, 0.075), 0 0 6px #7ab5d3; -} - -.control-group.info .input-prepend .add-on, -.control-group.info .input-append .add-on { - color: #3a87ad; - background-color: #d9edf7; - border-color: #3a87ad; -} - -input:focus:invalid, -textarea:focus:invalid, -select:focus:invalid { - color: #b94a48; - border-color: #ee5f5b; -} - -input:focus:invalid:focus, -textarea:focus:invalid:focus, -select:focus:invalid:focus { - border-color: #e9322d; - -webkit-box-shadow: 0 0 6px #f8b9b7; - -moz-box-shadow: 0 0 6px #f8b9b7; - box-shadow: 0 0 6px #f8b9b7; -} - -.form-actions { - padding: 19px 20px 20px; - margin-top: 20px; - margin-bottom: 20px; - background-color: #f5f5f5; - border-top: 1px solid #e5e5e5; - *zoom: 1; -} - -.form-actions:before, -.form-actions:after { - display: table; - line-height: 0; - content: ""; -} - -.form-actions:after { - clear: both; -} - -.help-block, -.help-inline { - color: #595959; -} - -.help-block { - display: block; - margin-bottom: 10px; -} - -.help-inline { - display: inline-block; - *display: inline; - padding-left: 5px; - vertical-align: middle; - *zoom: 1; -} - -.input-append, -.input-prepend { - display: inline-block; - margin-bottom: 10px; - font-size: 0; - white-space: nowrap; - vertical-align: middle; -} - -.input-append input, -.input-prepend input, -.input-append select, -.input-prepend select, -.input-append .uneditable-input, -.input-prepend .uneditable-input, -.input-append .dropdown-menu, -.input-prepend .dropdown-menu, -.input-append .popover, -.input-prepend .popover { - font-size: 14px; -} - -.input-append input, -.input-prepend input, -.input-append select, -.input-prepend select, -.input-append .uneditable-input, -.input-prepend .uneditable-input { - position: relative; - margin-bottom: 0; - *margin-left: 0; - vertical-align: top; - -webkit-border-radius: 0 4px 4px 0; - -moz-border-radius: 0 4px 4px 0; - border-radius: 0 4px 4px 0; -} - -.input-append input:focus, -.input-prepend input:focus, -.input-append select:focus, -.input-prepend select:focus, -.input-append .uneditable-input:focus, -.input-prepend .uneditable-input:focus { - z-index: 2; -} - -.input-append .add-on, -.input-prepend .add-on { - display: inline-block; - width: auto; - height: 20px; - min-width: 16px; - padding: 4px 5px; - font-size: 14px; - font-weight: normal; - line-height: 20px; - text-align: center; - text-shadow: 0 1px 0 #ffffff; - background-color: #eeeeee; - border: 1px solid #ccc; -} - -.input-append .add-on, -.input-prepend .add-on, -.input-append .btn, -.input-prepend .btn, -.input-append .btn-group > .dropdown-toggle, -.input-prepend .btn-group > .dropdown-toggle { - vertical-align: top; - -webkit-border-radius: 0; - -moz-border-radius: 0; - border-radius: 0; -} - -.input-append .active, -.input-prepend .active { - background-color: #a9dba9; - border-color: #46a546; -} - -.input-prepend .add-on, -.input-prepend .btn { - margin-right: -1px; -} - -.input-prepend .add-on:first-child, -.input-prepend .btn:first-child { - -webkit-border-radius: 4px 0 0 4px; - -moz-border-radius: 4px 0 0 4px; - border-radius: 4px 0 0 4px; -} - -.input-append input, -.input-append select, -.input-append .uneditable-input { - -webkit-border-radius: 4px 0 0 4px; - -moz-border-radius: 4px 0 0 4px; - border-radius: 4px 0 0 4px; -} - -.input-append input + .btn-group .btn:last-child, -.input-append select + .btn-group .btn:last-child, -.input-append .uneditable-input + .btn-group .btn:last-child { - -webkit-border-radius: 0 4px 4px 0; - -moz-border-radius: 0 4px 4px 0; - border-radius: 0 4px 4px 0; -} - -.input-append .add-on, -.input-append .btn, -.input-append .btn-group { - margin-left: -1px; -} - -.input-append .add-on:last-child, -.input-append .btn:last-child, -.input-append .btn-group:last-child > .dropdown-toggle { - -webkit-border-radius: 0 4px 4px 0; - -moz-border-radius: 0 4px 4px 0; - border-radius: 0 4px 4px 0; -} - -.input-prepend.input-append input, -.input-prepend.input-append select, -.input-prepend.input-append .uneditable-input { - -webkit-border-radius: 0; - -moz-border-radius: 0; - border-radius: 0; -} - -.input-prepend.input-append input + .btn-group .btn, -.input-prepend.input-append select + .btn-group .btn, -.input-prepend.input-append .uneditable-input + .btn-group .btn { - -webkit-border-radius: 0 4px 4px 0; - -moz-border-radius: 0 4px 4px 0; - border-radius: 0 4px 4px 0; -} - -.input-prepend.input-append .add-on:first-child, -.input-prepend.input-append .btn:first-child { - margin-right: -1px; - -webkit-border-radius: 4px 0 0 4px; - -moz-border-radius: 4px 0 0 4px; - border-radius: 4px 0 0 4px; -} - -.input-prepend.input-append .add-on:last-child, -.input-prepend.input-append .btn:last-child { - margin-left: -1px; - -webkit-border-radius: 0 4px 4px 0; - -moz-border-radius: 0 4px 4px 0; - border-radius: 0 4px 4px 0; -} - -.input-prepend.input-append .btn-group:first-child { - margin-left: 0; -} - -input.search-query { - padding-right: 14px; - padding-right: 4px \9; - padding-left: 14px; - padding-left: 4px \9; - /* IE7-8 doesn't have border-radius, so don't indent the padding */ - - margin-bottom: 0; - -webkit-border-radius: 15px; - -moz-border-radius: 15px; - border-radius: 15px; -} - -/* Allow for input prepend/append in search forms */ - -.form-search .input-append .search-query, -.form-search .input-prepend .search-query { - -webkit-border-radius: 0; - -moz-border-radius: 0; - border-radius: 0; -} - -.form-search .input-append .search-query { - -webkit-border-radius: 14px 0 0 14px; - -moz-border-radius: 14px 0 0 14px; - border-radius: 14px 0 0 14px; -} - -.form-search .input-append .btn { - -webkit-border-radius: 0 14px 14px 0; - -moz-border-radius: 0 14px 14px 0; - border-radius: 0 14px 14px 0; -} - -.form-search .input-prepend .search-query { - -webkit-border-radius: 0 14px 14px 0; - -moz-border-radius: 0 14px 14px 0; - border-radius: 0 14px 14px 0; -} - -.form-search .input-prepend .btn { - -webkit-border-radius: 14px 0 0 14px; - -moz-border-radius: 14px 0 0 14px; - border-radius: 14px 0 0 14px; -} - -.form-search input, -.form-inline input, -.form-horizontal input, -.form-search textarea, -.form-inline textarea, -.form-horizontal textarea, -.form-search select, -.form-inline select, -.form-horizontal select, -.form-search .help-inline, -.form-inline .help-inline, -.form-horizontal .help-inline, -.form-search .uneditable-input, -.form-inline .uneditable-input, -.form-horizontal .uneditable-input, -.form-search .input-prepend, -.form-inline .input-prepend, -.form-horizontal .input-prepend, -.form-search .input-append, -.form-inline .input-append, -.form-horizontal .input-append { - display: inline-block; - *display: inline; - margin-bottom: 0; - vertical-align: middle; - *zoom: 1; -} - -.form-search .hide, -.form-inline .hide, -.form-horizontal .hide { - display: none; -} - -.form-search label, -.form-inline label, -.form-search .btn-group, -.form-inline .btn-group { - display: inline-block; -} - -.form-search .input-append, -.form-inline .input-append, -.form-search .input-prepend, -.form-inline .input-prepend { - margin-bottom: 0; -} - -.form-search .radio, -.form-search .checkbox, -.form-inline .radio, -.form-inline .checkbox { - padding-left: 0; - margin-bottom: 0; - vertical-align: middle; -} - -.form-search .radio input[type="radio"], -.form-search .checkbox input[type="checkbox"], -.form-inline .radio input[type="radio"], -.form-inline .checkbox input[type="checkbox"] { - float: left; - margin-right: 3px; - margin-left: 0; -} - -.control-group { - margin-bottom: 10px; -} - -legend + .control-group { - margin-top: 20px; - -webkit-margin-top-collapse: separate; -} - -.form-horizontal .control-group { - margin-bottom: 20px; - *zoom: 1; -} - -.form-horizontal .control-group:before, -.form-horizontal .control-group:after { - display: table; - line-height: 0; - content: ""; -} - -.form-horizontal .control-group:after { - clear: both; -} - -.form-horizontal .control-label { - float: left; - width: 160px; - padding-top: 5px; - text-align: right; -} - -.form-horizontal .controls { - *display: inline-block; - *padding-left: 20px; - margin-left: 180px; - *margin-left: 0; -} - -.form-horizontal .controls:first-child { - *padding-left: 180px; -} - -.form-horizontal .help-block { - margin-bottom: 0; -} - -.form-horizontal input + .help-block, -.form-horizontal select + .help-block, -.form-horizontal textarea + .help-block, -.form-horizontal .uneditable-input + .help-block, -.form-horizontal .input-prepend + .help-block, -.form-horizontal .input-append + .help-block { - margin-top: 10px; -} - -.form-horizontal .form-actions { - padding-left: 180px; -} - -table { - max-width: 100%; - background-color: transparent; - border-collapse: collapse; - border-spacing: 0; -} - -.table { - width: 100%; - margin-bottom: 20px; -} - -.table th, -.table td { - padding: 8px; - line-height: 20px; - text-align: left; - vertical-align: top; - border-top: 1px solid #dddddd; -} - -.table th { - font-weight: bold; -} - -.table thead th { - vertical-align: bottom; -} - -.table caption + thead tr:first-child th, -.table caption + thead tr:first-child td, -.table colgroup + thead tr:first-child th, -.table colgroup + thead tr:first-child td, -.table thead:first-child tr:first-child th, -.table thead:first-child tr:first-child td { - border-top: 0; -} - -.table tbody + tbody { - border-top: 2px solid #dddddd; -} - -.table .table { - background-color: #ffffff; -} - -.table-condensed th, -.table-condensed td { - padding: 4px 5px; -} - -.table-bordered { - border: 1px solid #dddddd; - border-collapse: separate; - *border-collapse: collapse; - border-left: 0; - -webkit-border-radius: 4px; - -moz-border-radius: 4px; - border-radius: 4px; -} - -.table-bordered th, -.table-bordered td { - border-left: 1px solid #dddddd; -} - -.table-bordered caption + thead tr:first-child th, -.table-bordered caption + tbody tr:first-child th, -.table-bordered caption + tbody tr:first-child td, -.table-bordered colgroup + thead tr:first-child th, -.table-bordered colgroup + tbody tr:first-child th, -.table-bordered colgroup + tbody tr:first-child td, -.table-bordered thead:first-child tr:first-child th, -.table-bordered tbody:first-child tr:first-child th, -.table-bordered tbody:first-child tr:first-child td { - border-top: 0; -} - -.table-bordered thead:first-child tr:first-child > th:first-child, -.table-bordered tbody:first-child tr:first-child > td:first-child, -.table-bordered tbody:first-child tr:first-child > th:first-child { - -webkit-border-top-left-radius: 4px; - border-top-left-radius: 4px; - -moz-border-radius-topleft: 4px; -} - -.table-bordered thead:first-child tr:first-child > th:last-child, -.table-bordered tbody:first-child tr:first-child > td:last-child, -.table-bordered tbody:first-child tr:first-child > th:last-child { - -webkit-border-top-right-radius: 4px; - border-top-right-radius: 4px; - -moz-border-radius-topright: 4px; -} - -.table-bordered thead:last-child tr:last-child > th:first-child, -.table-bordered tbody:last-child tr:last-child > td:first-child, -.table-bordered tbody:last-child tr:last-child > th:first-child, -.table-bordered tfoot:last-child tr:last-child > td:first-child, -.table-bordered tfoot:last-child tr:last-child > th:first-child { - -webkit-border-bottom-left-radius: 4px; - border-bottom-left-radius: 4px; - -moz-border-radius-bottomleft: 4px; -} - -.table-bordered thead:last-child tr:last-child > th:last-child, -.table-bordered tbody:last-child tr:last-child > td:last-child, -.table-bordered tbody:last-child tr:last-child > th:last-child, -.table-bordered tfoot:last-child tr:last-child > td:last-child, -.table-bordered tfoot:last-child tr:last-child > th:last-child { - -webkit-border-bottom-right-radius: 4px; - border-bottom-right-radius: 4px; - -moz-border-radius-bottomright: 4px; -} - -.table-bordered tfoot + tbody:last-child tr:last-child td:first-child { - -webkit-border-bottom-left-radius: 0; - border-bottom-left-radius: 0; - -moz-border-radius-bottomleft: 0; -} - -.table-bordered tfoot + tbody:last-child tr:last-child td:last-child { - -webkit-border-bottom-right-radius: 0; - border-bottom-right-radius: 0; - -moz-border-radius-bottomright: 0; -} - -.table-bordered caption + thead tr:first-child th:first-child, -.table-bordered caption + tbody tr:first-child td:first-child, -.table-bordered colgroup + thead tr:first-child th:first-child, -.table-bordered colgroup + tbody tr:first-child td:first-child { - -webkit-border-top-left-radius: 4px; - border-top-left-radius: 4px; - -moz-border-radius-topleft: 4px; -} - -.table-bordered caption + thead tr:first-child th:last-child, -.table-bordered caption + tbody tr:first-child td:last-child, -.table-bordered colgroup + thead tr:first-child th:last-child, -.table-bordered colgroup + tbody tr:first-child td:last-child { - -webkit-border-top-right-radius: 4px; - border-top-right-radius: 4px; - -moz-border-radius-topright: 4px; -} - -.table-striped tbody > tr:nth-child(odd) > td, -.table-striped tbody > tr:nth-child(odd) > th { - background-color: #f9f9f9; -} - -.table-hover tbody tr:hover > td, -.table-hover tbody tr:hover > th { - background-color: #f5f5f5; -} - -table td[class*="span"], -table th[class*="span"], -.row-fluid table td[class*="span"], -.row-fluid table th[class*="span"] { - display: table-cell; - float: none; - margin-left: 0; -} - -.table td.span1, -.table th.span1 { - float: none; - width: 44px; - margin-left: 0; -} - -.table td.span2, -.table th.span2 { - float: none; - width: 124px; - margin-left: 0; -} - -.table td.span3, -.table th.span3 { - float: none; - width: 204px; - margin-left: 0; -} - -.table td.span4, -.table th.span4 { - float: none; - width: 284px; - margin-left: 0; -} - -.table td.span5, -.table th.span5 { - float: none; - width: 364px; - margin-left: 0; -} - -.table td.span6, -.table th.span6 { - float: none; - width: 444px; - margin-left: 0; -} - -.table td.span7, -.table th.span7 { - float: none; - width: 524px; - margin-left: 0; -} - -.table td.span8, -.table th.span8 { - float: none; - width: 604px; - margin-left: 0; -} - -.table td.span9, -.table th.span9 { - float: none; - width: 684px; - margin-left: 0; -} - -.table td.span10, -.table th.span10 { - float: none; - width: 764px; - margin-left: 0; -} - -.table td.span11, -.table th.span11 { - float: none; - width: 844px; - margin-left: 0; -} - -.table td.span12, -.table th.span12 { - float: none; - width: 924px; - margin-left: 0; -} - -.table tbody tr.success > td { - background-color: #dff0d8; -} - -.table tbody tr.error > td { - background-color: #f2dede; -} - -.table tbody tr.warning > td { - background-color: #fcf8e3; -} - -.table tbody tr.info > td { - background-color: #d9edf7; -} - -.table-hover tbody tr.success:hover > td { - background-color: #d0e9c6; -} - -.table-hover tbody tr.error:hover > td { - background-color: #ebcccc; -} - -.table-hover tbody tr.warning:hover > td { - background-color: #faf2cc; -} - -.table-hover tbody tr.info:hover > td { - background-color: #c4e3f3; -} - -[class^="icon-"], -[class*=" icon-"] { - display: inline-block; - width: 14px; - height: 14px; - margin-top: 1px; - *margin-right: .3em; - line-height: 14px; - vertical-align: text-top; - background-image: url("../images/glyphicons-halflings.png"); - background-position: 14px 14px; - background-repeat: no-repeat; -} - -/* White icons with optional class, or on hover/focus/active states of certain elements */ - -.icon-white, -.nav-pills > .active > a > [class^="icon-"], -.nav-pills > .active > a > [class*=" icon-"], -.nav-list > .active > a > [class^="icon-"], -.nav-list > .active > a > [class*=" icon-"], -.navbar-inverse .nav > .active > a > [class^="icon-"], -.navbar-inverse .nav > .active > a > [class*=" icon-"], -.dropdown-menu > li > a:hover > [class^="icon-"], -.dropdown-menu > li > a:focus > [class^="icon-"], -.dropdown-menu > li > a:hover > [class*=" icon-"], -.dropdown-menu > li > a:focus > [class*=" icon-"], -.dropdown-menu > .active > a > [class^="icon-"], -.dropdown-menu > .active > a > [class*=" icon-"], -.dropdown-submenu:hover > a > [class^="icon-"], -.dropdown-submenu:focus > a > [class^="icon-"], -.dropdown-submenu:hover > a > [class*=" icon-"], -.dropdown-submenu:focus > a > [class*=" icon-"] { - background-image: url("../images/glyphicons-halflings-white.png"); -} - -.icon-glass { - background-position: 0 0; -} - -.icon-music { - background-position: -24px 0; -} - -.icon-search { - background-position: -48px 0; -} - -.icon-envelope { - background-position: -72px 0; -} - -.icon-heart { - background-position: -96px 0; -} - -.icon-star { - background-position: -120px 0; -} - -.icon-star-empty { - background-position: -144px 0; -} - -.icon-user { - background-position: -168px 0; -} - -.icon-film { - background-position: -192px 0; -} - -.icon-th-large { - background-position: -216px 0; -} - -.icon-th { - background-position: -240px 0; -} - -.icon-th-list { - background-position: -264px 0; -} - -.icon-ok { - background-position: -288px 0; -} - -.icon-remove { - background-position: -312px 0; -} - -.icon-zoom-in { - background-position: -336px 0; -} - -.icon-zoom-out { - background-position: -360px 0; -} - -.icon-off { - background-position: -384px 0; -} - -.icon-signal { - background-position: -408px 0; -} - -.icon-cog { - background-position: -432px 0; -} - -.icon-trash { - background-position: -456px 0; -} - -.icon-home { - background-position: 0 -24px; -} - -.icon-file { - background-position: -24px -24px; -} - -.icon-time { - background-position: -48px -24px; -} - -.icon-road { - background-position: -72px -24px; -} - -.icon-download-alt { - background-position: -96px -24px; -} - -.icon-download { - background-position: -120px -24px; -} - -.icon-upload { - background-position: -144px -24px; -} - -.icon-inbox { - background-position: -168px -24px; -} - -.icon-play-circle { - background-position: -192px -24px; -} - -.icon-repeat { - background-position: -216px -24px; -} - -.icon-refresh { - background-position: -240px -24px; -} - -.icon-list-alt { - background-position: -264px -24px; -} - -.icon-lock { - background-position: -287px -24px; -} - -.icon-flag { - background-position: -312px -24px; -} - -.icon-headphones { - background-position: -336px -24px; -} - -.icon-volume-off { - background-position: -360px -24px; -} - -.icon-volume-down { - background-position: -384px -24px; -} - -.icon-volume-up { - background-position: -408px -24px; -} - -.icon-qrcode { - background-position: -432px -24px; -} - -.icon-barcode { - background-position: -456px -24px; -} - -.icon-tag { - background-position: 0 -48px; -} - -.icon-tags { - background-position: -25px -48px; -} - -.icon-book { - background-position: -48px -48px; -} - -.icon-bookmark { - background-position: -72px -48px; -} - -.icon-print { - background-position: -96px -48px; -} - -.icon-camera { - background-position: -120px -48px; -} - -.icon-font { - background-position: -144px -48px; -} - -.icon-bold { - background-position: -167px -48px; -} - -.icon-italic { - background-position: -192px -48px; -} - -.icon-text-height { - background-position: -216px -48px; -} - -.icon-text-width { - background-position: -240px -48px; -} - -.icon-align-left { - background-position: -264px -48px; -} - -.icon-align-center { - background-position: -288px -48px; -} - -.icon-align-right { - background-position: -312px -48px; -} - -.icon-align-justify { - background-position: -336px -48px; -} - -.icon-list { - background-position: -360px -48px; -} - -.icon-indent-left { - background-position: -384px -48px; -} - -.icon-indent-right { - background-position: -408px -48px; -} - -.icon-facetime-video { - background-position: -432px -48px; -} - -.icon-picture { - background-position: -456px -48px; -} - -.icon-pencil { - background-position: 0 -72px; -} - -.icon-map-marker { - background-position: -24px -72px; -} - -.icon-adjust { - background-position: -48px -72px; -} - -.icon-tint { - background-position: -72px -72px; -} - -.icon-edit { - background-position: -96px -72px; -} - -.icon-share { - background-position: -120px -72px; -} - -.icon-check { - background-position: -144px -72px; -} - -.icon-move { - background-position: -168px -72px; -} - -.icon-step-backward { - background-position: -192px -72px; -} - -.icon-fast-backward { - background-position: -216px -72px; -} - -.icon-backward { - background-position: -240px -72px; -} - -.icon-play { - background-position: -264px -72px; -} - -.icon-pause { - background-position: -288px -72px; -} - -.icon-stop { - background-position: -312px -72px; -} - -.icon-forward { - background-position: -336px -72px; -} - -.icon-fast-forward { - background-position: -360px -72px; -} - -.icon-step-forward { - background-position: -384px -72px; -} - -.icon-eject { - background-position: -408px -72px; -} - -.icon-chevron-left { - background-position: -432px -72px; -} - -.icon-chevron-right { - background-position: -456px -72px; -} - -.icon-plus-sign { - background-position: 0 -96px; -} - -.icon-minus-sign { - background-position: -24px -96px; -} - -.icon-remove-sign { - background-position: -48px -96px; -} - -.icon-ok-sign { - background-position: -72px -96px; -} - -.icon-question-sign { - background-position: -96px -96px; -} - -.icon-info-sign { - background-position: -120px -96px; -} - -.icon-screenshot { - background-position: -144px -96px; -} - -.icon-remove-circle { - background-position: -168px -96px; -} - -.icon-ok-circle { - background-position: -192px -96px; -} - -.icon-ban-circle { - background-position: -216px -96px; -} - -.icon-arrow-left { - background-position: -240px -96px; -} - -.icon-arrow-right { - background-position: -264px -96px; -} - -.icon-arrow-up { - background-position: -289px -96px; -} - -.icon-arrow-down { - background-position: -312px -96px; -} - -.icon-share-alt { - background-position: -336px -96px; -} - -.icon-resize-full { - background-position: -360px -96px; -} - -.icon-resize-small { - background-position: -384px -96px; -} - -.icon-plus { - background-position: -408px -96px; -} - -.icon-minus { - background-position: -433px -96px; -} - -.icon-asterisk { - background-position: -456px -96px; -} - -.icon-exclamation-sign { - background-position: 0 -120px; -} - -.icon-gift { - background-position: -24px -120px; -} - -.icon-leaf { - background-position: -48px -120px; -} - -.icon-fire { - background-position: -72px -120px; -} - -.icon-eye-open { - background-position: -96px -120px; -} - -.icon-eye-close { - background-position: -120px -120px; -} - -.icon-warning-sign { - background-position: -144px -120px; -} - -.icon-plane { - background-position: -168px -120px; -} - -.icon-calendar { - background-position: -192px -120px; -} - -.icon-random { - width: 16px; - background-position: -216px -120px; -} - -.icon-comment { - background-position: -240px -120px; -} - -.icon-magnet { - background-position: -264px -120px; -} - -.icon-chevron-up { - background-position: -288px -120px; -} - -.icon-chevron-down { - background-position: -313px -119px; -} - -.icon-retweet { - background-position: -336px -120px; -} - -.icon-shopping-cart { - background-position: -360px -120px; -} - -.icon-folder-close { - width: 16px; - background-position: -384px -120px; -} - -.icon-folder-open { - width: 16px; - background-position: -408px -120px; -} - -.icon-resize-vertical { - background-position: -432px -119px; -} - -.icon-resize-horizontal { - background-position: -456px -118px; -} - -.icon-hdd { - background-position: 0 -144px; -} - -.icon-bullhorn { - background-position: -24px -144px; -} - -.icon-bell { - background-position: -48px -144px; -} - -.icon-certificate { - background-position: -72px -144px; -} - -.icon-thumbs-up { - background-position: -96px -144px; -} - -.icon-thumbs-down { - background-position: -120px -144px; -} - -.icon-hand-right { - background-position: -144px -144px; -} - -.icon-hand-left { - background-position: -168px -144px; -} - -.icon-hand-up { - background-position: -192px -144px; -} - -.icon-hand-down { - background-position: -216px -144px; -} - -.icon-circle-arrow-right { - background-position: -240px -144px; -} - -.icon-circle-arrow-left { - background-position: -264px -144px; -} - -.icon-circle-arrow-up { - background-position: -288px -144px; -} - -.icon-circle-arrow-down { - background-position: -312px -144px; -} - -.icon-globe { - background-position: -336px -144px; -} - -.icon-wrench { - background-position: -360px -144px; -} - -.icon-tasks { - background-position: -384px -144px; -} - -.icon-filter { - background-position: -408px -144px; -} - -.icon-briefcase { - background-position: -432px -144px; -} - -.icon-fullscreen { - background-position: -456px -144px; -} - -.dropup, -.dropdown { - position: relative; -} - -.dropdown-toggle { - *margin-bottom: -3px; -} - -.dropdown-toggle:active, -.open .dropdown-toggle { - outline: 0; -} - -.caret { - display: inline-block; - width: 0; - height: 0; - vertical-align: top; - border-top: 4px solid #000000; - border-right: 4px solid transparent; - border-left: 4px solid transparent; - content: ""; -} - -.dropdown .caret { - margin-top: 8px; - margin-left: 2px; -} - -.dropdown-menu { - position: absolute; - top: 100%; - left: 0; - z-index: 1000; - display: none; - float: left; - min-width: 160px; - padding: 5px 0; - margin: 2px 0 0; - list-style: none; - background-color: #ffffff; - border: 1px solid #ccc; - border: 1px solid rgba(0, 0, 0, 0.2); - *border-right-width: 2px; - *border-bottom-width: 2px; - -webkit-border-radius: 6px; - -moz-border-radius: 6px; - border-radius: 6px; - -webkit-box-shadow: 0 5px 10px rgba(0, 0, 0, 0.2); - -moz-box-shadow: 0 5px 10px rgba(0, 0, 0, 0.2); - box-shadow: 0 5px 10px rgba(0, 0, 0, 0.2); - -webkit-background-clip: padding-box; - -moz-background-clip: padding; - background-clip: padding-box; -} - -.dropdown-menu.pull-right { - right: 0; - left: auto; -} - -.dropdown-menu .divider { - *width: 100%; - height: 1px; - margin: 9px 1px; - *margin: -5px 0 5px; - overflow: hidden; - background-color: #e5e5e5; - border-bottom: 1px solid #ffffff; -} - -.dropdown-menu > li > a { - display: block; - padding: 3px 20px; - clear: both; - font-weight: normal; - line-height: 20px; - color: #333333; - white-space: nowrap; -} - -.dropdown-menu > li > a:hover, -.dropdown-menu > li > a:focus, -.dropdown-submenu:hover > a, -.dropdown-submenu:focus > a { - color: #ffffff; - text-decoration: none; - background-color: #0081c2; - background-image: -moz-linear-gradient(top, #0088cc, #0077b3); - background-image: -webkit-gradient(linear, 0 0, 0 100%, from(#0088cc), to(#0077b3)); - background-image: -webkit-linear-gradient(top, #0088cc, #0077b3); - background-image: -o-linear-gradient(top, #0088cc, #0077b3); - background-image: linear-gradient(to bottom, #0088cc, #0077b3); - background-repeat: repeat-x; - filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#ff0088cc', endColorstr='#ff0077b3', GradientType=0); -} - -.dropdown-menu > .active > a, -.dropdown-menu > .active > a:hover, -.dropdown-menu > .active > a:focus { - color: #ffffff; - text-decoration: none; - background-color: #0081c2; - background-image: -moz-linear-gradient(top, #0088cc, #0077b3); - background-image: -webkit-gradient(linear, 0 0, 0 100%, from(#0088cc), to(#0077b3)); - background-image: -webkit-linear-gradient(top, #0088cc, #0077b3); - background-image: -o-linear-gradient(top, #0088cc, #0077b3); - background-image: linear-gradient(to bottom, #0088cc, #0077b3); - background-repeat: repeat-x; - outline: 0; - filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#ff0088cc', endColorstr='#ff0077b3', GradientType=0); -} - -.dropdown-menu > .disabled > a, -.dropdown-menu > .disabled > a:hover, -.dropdown-menu > .disabled > a:focus { - color: #999999; -} - -.dropdown-menu > .disabled > a:hover, -.dropdown-menu > .disabled > a:focus { - text-decoration: none; - cursor: default; - background-color: transparent; - background-image: none; - filter: progid:DXImageTransform.Microsoft.gradient(enabled=false); -} - -.open { - *z-index: 1000; -} - -.open > .dropdown-menu { - display: block; -} - -.dropdown-backdrop { - position: fixed; - top: 0; - right: 0; - bottom: 0; - left: 0; - z-index: 990; -} - -.pull-right > .dropdown-menu { - right: 0; - left: auto; -} - -.dropup .caret, -.navbar-fixed-bottom .dropdown .caret { - border-top: 0; - border-bottom: 4px solid #000000; - content: ""; -} - -.dropup .dropdown-menu, -.navbar-fixed-bottom .dropdown .dropdown-menu { - top: auto; - bottom: 100%; - margin-bottom: 1px; -} - -.dropdown-submenu { - position: relative; -} - -.dropdown-submenu > .dropdown-menu { - top: 0; - left: 100%; - margin-top: -6px; - margin-left: -1px; - -webkit-border-radius: 0 6px 6px 6px; - -moz-border-radius: 0 6px 6px 6px; - border-radius: 0 6px 6px 6px; -} - -.dropdown-submenu:hover > .dropdown-menu { - display: block; -} - -.dropup .dropdown-submenu > .dropdown-menu { - top: auto; - bottom: 0; - margin-top: 0; - margin-bottom: -2px; - -webkit-border-radius: 5px 5px 5px 0; - -moz-border-radius: 5px 5px 5px 0; - border-radius: 5px 5px 5px 0; -} - -.dropdown-submenu > a:after { - display: block; - float: right; - width: 0; - height: 0; - margin-top: 5px; - margin-right: -10px; - border-color: transparent; - border-left-color: #cccccc; - border-style: solid; - border-width: 5px 0 5px 5px; - content: " "; -} - -.dropdown-submenu:hover > a:after { - border-left-color: #ffffff; -} - -.dropdown-submenu.pull-left { - float: none; -} - -.dropdown-submenu.pull-left > .dropdown-menu { - left: -100%; - margin-left: 10px; - -webkit-border-radius: 6px 0 6px 6px; - -moz-border-radius: 6px 0 6px 6px; - border-radius: 6px 0 6px 6px; -} - -.dropdown .dropdown-menu .nav-header { - padding-right: 20px; - padding-left: 20px; -} - -.typeahead { - z-index: 1051; - margin-top: 2px; - -webkit-border-radius: 4px; - -moz-border-radius: 4px; - border-radius: 4px; -} - -.well { - min-height: 20px; - padding: 19px; - margin-bottom: 20px; - background-color: #f5f5f5; - border: 1px solid #e3e3e3; - -webkit-border-radius: 4px; - -moz-border-radius: 4px; - border-radius: 4px; - -webkit-box-shadow: inset 0 1px 1px rgba(0, 0, 0, 0.05); - -moz-box-shadow: inset 0 1px 1px rgba(0, 0, 0, 0.05); - box-shadow: inset 0 1px 1px rgba(0, 0, 0, 0.05); -} - -.well blockquote { - border-color: #ddd; - border-color: rgba(0, 0, 0, 0.15); -} - -.well-large { - padding: 24px; - -webkit-border-radius: 6px; - -moz-border-radius: 6px; - border-radius: 6px; -} - -.well-small { - padding: 9px; - -webkit-border-radius: 3px; - -moz-border-radius: 3px; - border-radius: 3px; -} - -.fade { - opacity: 0; - -webkit-transition: opacity 0.15s linear; - -moz-transition: opacity 0.15s linear; - -o-transition: opacity 0.15s linear; - transition: opacity 0.15s linear; -} - -.fade.in { - opacity: 1; -} - -.collapse { - position: relative; - height: 0; - overflow: hidden; - -webkit-transition: height 0.35s ease; - -moz-transition: height 0.35s ease; - -o-transition: height 0.35s ease; - transition: height 0.35s ease; -} - -.collapse.in { - height: auto; -} - -.close { - float: right; - font-size: 20px; - font-weight: bold; - line-height: 20px; - color: #000000; - text-shadow: 0 1px 0 #ffffff; - opacity: 0.2; - filter: alpha(opacity=20); -} - -.close:hover, -.close:focus { - color: #000000; - text-decoration: none; - cursor: pointer; - opacity: 0.4; - filter: alpha(opacity=40); -} - -button.close { - padding: 0; - cursor: pointer; - background: transparent; - border: 0; - -webkit-appearance: none; -} - -.btn { - display: inline-block; - *display: inline; - padding: 4px 12px; - margin-bottom: 0; - *margin-left: .3em; - font-size: 14px; - line-height: 20px; - color: #333333; - text-align: center; - text-shadow: 0 1px 1px rgba(255, 255, 255, 0.75); - vertical-align: middle; - cursor: pointer; - background-color: #f5f5f5; - *background-color: #e6e6e6; - background-image: -moz-linear-gradient(top, #ffffff, #e6e6e6); - background-image: -webkit-gradient(linear, 0 0, 0 100%, from(#ffffff), to(#e6e6e6)); - background-image: -webkit-linear-gradient(top, #ffffff, #e6e6e6); - background-image: -o-linear-gradient(top, #ffffff, #e6e6e6); - background-image: linear-gradient(to bottom, #ffffff, #e6e6e6); - background-repeat: repeat-x; - border: 1px solid #cccccc; - *border: 0; - border-color: #e6e6e6 #e6e6e6 #bfbfbf; - border-color: rgba(0, 0, 0, 0.1) rgba(0, 0, 0, 0.1) rgba(0, 0, 0, 0.25); - border-bottom-color: #b3b3b3; - -webkit-border-radius: 4px; - -moz-border-radius: 4px; - border-radius: 4px; - filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#ffffffff', endColorstr='#ffe6e6e6', GradientType=0); - filter: progid:DXImageTransform.Microsoft.gradient(enabled=false); - *zoom: 1; - -webkit-box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.2), 0 1px 2px rgba(0, 0, 0, 0.05); - -moz-box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.2), 0 1px 2px rgba(0, 0, 0, 0.05); - box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.2), 0 1px 2px rgba(0, 0, 0, 0.05); -} - -.btn:hover, -.btn:focus, -.btn:active, -.btn.active, -.btn.disabled, -.btn[disabled] { - color: #333333; - background-color: #e6e6e6; - *background-color: #d9d9d9; -} - -.btn:active, -.btn.active { - background-color: #cccccc \9; -} - -.btn:first-child { - *margin-left: 0; -} - -.btn:hover, -.btn:focus { - color: #333333; - text-decoration: none; - background-position: 0 -15px; - -webkit-transition: background-position 0.1s linear; - -moz-transition: background-position 0.1s linear; - -o-transition: background-position 0.1s linear; - transition: background-position 0.1s linear; -} - -.btn:focus { - outline: thin dotted #333; - outline: 5px auto -webkit-focus-ring-color; - outline-offset: -2px; -} - -.btn.active, -.btn:active { - background-image: none; - outline: 0; - -webkit-box-shadow: inset 0 2px 4px rgba(0, 0, 0, 0.15), 0 1px 2px rgba(0, 0, 0, 0.05); - -moz-box-shadow: inset 0 2px 4px rgba(0, 0, 0, 0.15), 0 1px 2px rgba(0, 0, 0, 0.05); - box-shadow: inset 0 2px 4px rgba(0, 0, 0, 0.15), 0 1px 2px rgba(0, 0, 0, 0.05); -} - -.btn.disabled, -.btn[disabled] { - cursor: default; - background-image: none; - opacity: 0.65; - filter: alpha(opacity=65); - -webkit-box-shadow: none; - -moz-box-shadow: none; - box-shadow: none; -} - -.btn-large { - padding: 11px 19px; - font-size: 17.5px; - -webkit-border-radius: 6px; - -moz-border-radius: 6px; - border-radius: 6px; -} - -.btn-large [class^="icon-"], -.btn-large [class*=" icon-"] { - margin-top: 4px; -} - -.btn-small { - padding: 2px 10px; - font-size: 11.9px; - -webkit-border-radius: 3px; - -moz-border-radius: 3px; - border-radius: 3px; -} - -.btn-small [class^="icon-"], -.btn-small [class*=" icon-"] { - margin-top: 0; -} - -.btn-mini [class^="icon-"], -.btn-mini [class*=" icon-"] { - margin-top: -1px; -} - -.btn-mini { - padding: 0 6px; - font-size: 10.5px; - -webkit-border-radius: 3px; - -moz-border-radius: 3px; - border-radius: 3px; -} - -.btn-block { - display: block; - width: 100%; - padding-right: 0; - padding-left: 0; - -webkit-box-sizing: border-box; - -moz-box-sizing: border-box; - box-sizing: border-box; -} - -.btn-block + .btn-block { - margin-top: 5px; -} - -input[type="submit"].btn-block, -input[type="reset"].btn-block, -input[type="button"].btn-block { - width: 100%; -} - -.btn-primary.active, -.btn-warning.active, -.btn-danger.active, -.btn-success.active, -.btn-info.active, -.btn-inverse.active { - color: rgba(255, 255, 255, 0.75); -} - -.btn-primary { - color: #ffffff; - text-shadow: 0 -1px 0 rgba(0, 0, 0, 0.25); - background-color: #006dcc; - *background-color: #0044cc; - background-image: -moz-linear-gradient(top, #0088cc, #0044cc); - background-image: -webkit-gradient(linear, 0 0, 0 100%, from(#0088cc), to(#0044cc)); - background-image: -webkit-linear-gradient(top, #0088cc, #0044cc); - background-image: -o-linear-gradient(top, #0088cc, #0044cc); - background-image: linear-gradient(to bottom, #0088cc, #0044cc); - background-repeat: repeat-x; - border-color: #0044cc #0044cc #002a80; - border-color: rgba(0, 0, 0, 0.1) rgba(0, 0, 0, 0.1) rgba(0, 0, 0, 0.25); - filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#ff0088cc', endColorstr='#ff0044cc', GradientType=0); - filter: progid:DXImageTransform.Microsoft.gradient(enabled=false); -} - -.btn-primary:hover, -.btn-primary:focus, -.btn-primary:active, -.btn-primary.active, -.btn-primary.disabled, -.btn-primary[disabled] { - color: #ffffff; - background-color: #0044cc; - *background-color: #003bb3; -} - -.btn-primary:active, -.btn-primary.active { - background-color: #003399 \9; -} - -.btn-warning { - color: #ffffff; - text-shadow: 0 -1px 0 rgba(0, 0, 0, 0.25); - background-color: #faa732; - *background-color: #f89406; - background-image: -moz-linear-gradient(top, #fbb450, #f89406); - background-image: -webkit-gradient(linear, 0 0, 0 100%, from(#fbb450), to(#f89406)); - background-image: -webkit-linear-gradient(top, #fbb450, #f89406); - background-image: -o-linear-gradient(top, #fbb450, #f89406); - background-image: linear-gradient(to bottom, #fbb450, #f89406); - background-repeat: repeat-x; - border-color: #f89406 #f89406 #ad6704; - border-color: rgba(0, 0, 0, 0.1) rgba(0, 0, 0, 0.1) rgba(0, 0, 0, 0.25); - filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#fffbb450', endColorstr='#fff89406', GradientType=0); - filter: progid:DXImageTransform.Microsoft.gradient(enabled=false); -} - -.btn-warning:hover, -.btn-warning:focus, -.btn-warning:active, -.btn-warning.active, -.btn-warning.disabled, -.btn-warning[disabled] { - color: #ffffff; - background-color: #f89406; - *background-color: #df8505; -} - -.btn-warning:active, -.btn-warning.active { - background-color: #c67605 \9; -} - -.btn-danger { - color: #ffffff; - text-shadow: 0 -1px 0 rgba(0, 0, 0, 0.25); - background-color: #da4f49; - *background-color: #bd362f; - background-image: -moz-linear-gradient(top, #ee5f5b, #bd362f); - background-image: -webkit-gradient(linear, 0 0, 0 100%, from(#ee5f5b), to(#bd362f)); - background-image: -webkit-linear-gradient(top, #ee5f5b, #bd362f); - background-image: -o-linear-gradient(top, #ee5f5b, #bd362f); - background-image: linear-gradient(to bottom, #ee5f5b, #bd362f); - background-repeat: repeat-x; - border-color: #bd362f #bd362f #802420; - border-color: rgba(0, 0, 0, 0.1) rgba(0, 0, 0, 0.1) rgba(0, 0, 0, 0.25); - filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#ffee5f5b', endColorstr='#ffbd362f', GradientType=0); - filter: progid:DXImageTransform.Microsoft.gradient(enabled=false); -} - -.btn-danger:hover, -.btn-danger:focus, -.btn-danger:active, -.btn-danger.active, -.btn-danger.disabled, -.btn-danger[disabled] { - color: #ffffff; - background-color: #bd362f; - *background-color: #a9302a; -} - -.btn-danger:active, -.btn-danger.active { - background-color: #942a25 \9; -} - -.btn-success { - color: #ffffff; - text-shadow: 0 -1px 0 rgba(0, 0, 0, 0.25); - background-color: #5bb75b; - *background-color: #51a351; - background-image: -moz-linear-gradient(top, #62c462, #51a351); - background-image: -webkit-gradient(linear, 0 0, 0 100%, from(#62c462), to(#51a351)); - background-image: -webkit-linear-gradient(top, #62c462, #51a351); - background-image: -o-linear-gradient(top, #62c462, #51a351); - background-image: linear-gradient(to bottom, #62c462, #51a351); - background-repeat: repeat-x; - border-color: #51a351 #51a351 #387038; - border-color: rgba(0, 0, 0, 0.1) rgba(0, 0, 0, 0.1) rgba(0, 0, 0, 0.25); - filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#ff62c462', endColorstr='#ff51a351', GradientType=0); - filter: progid:DXImageTransform.Microsoft.gradient(enabled=false); -} - -.btn-success:hover, -.btn-success:focus, -.btn-success:active, -.btn-success.active, -.btn-success.disabled, -.btn-success[disabled] { - color: #ffffff; - background-color: #51a351; - *background-color: #499249; -} - -.btn-success:active, -.btn-success.active { - background-color: #408140 \9; -} - -.btn-info { - color: #ffffff; - text-shadow: 0 -1px 0 rgba(0, 0, 0, 0.25); - background-color: #49afcd; - *background-color: #2f96b4; - background-image: -moz-linear-gradient(top, #5bc0de, #2f96b4); - background-image: -webkit-gradient(linear, 0 0, 0 100%, from(#5bc0de), to(#2f96b4)); - background-image: -webkit-linear-gradient(top, #5bc0de, #2f96b4); - background-image: -o-linear-gradient(top, #5bc0de, #2f96b4); - background-image: linear-gradient(to bottom, #5bc0de, #2f96b4); - background-repeat: repeat-x; - border-color: #2f96b4 #2f96b4 #1f6377; - border-color: rgba(0, 0, 0, 0.1) rgba(0, 0, 0, 0.1) rgba(0, 0, 0, 0.25); - filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#ff5bc0de', endColorstr='#ff2f96b4', GradientType=0); - filter: progid:DXImageTransform.Microsoft.gradient(enabled=false); -} - -.btn-info:hover, -.btn-info:focus, -.btn-info:active, -.btn-info.active, -.btn-info.disabled, -.btn-info[disabled] { - color: #ffffff; - background-color: #2f96b4; - *background-color: #2a85a0; -} - -.btn-info:active, -.btn-info.active { - background-color: #24748c \9; -} - -.btn-inverse { - color: #ffffff; - text-shadow: 0 -1px 0 rgba(0, 0, 0, 0.25); - background-color: #363636; - *background-color: #222222; - background-image: -moz-linear-gradient(top, #444444, #222222); - background-image: -webkit-gradient(linear, 0 0, 0 100%, from(#444444), to(#222222)); - background-image: -webkit-linear-gradient(top, #444444, #222222); - background-image: -o-linear-gradient(top, #444444, #222222); - background-image: linear-gradient(to bottom, #444444, #222222); - background-repeat: repeat-x; - border-color: #222222 #222222 #000000; - border-color: rgba(0, 0, 0, 0.1) rgba(0, 0, 0, 0.1) rgba(0, 0, 0, 0.25); - filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#ff444444', endColorstr='#ff222222', GradientType=0); - filter: progid:DXImageTransform.Microsoft.gradient(enabled=false); -} - -.btn-inverse:hover, -.btn-inverse:focus, -.btn-inverse:active, -.btn-inverse.active, -.btn-inverse.disabled, -.btn-inverse[disabled] { - color: #ffffff; - background-color: #222222; - *background-color: #151515; -} - -.btn-inverse:active, -.btn-inverse.active { - background-color: #080808 \9; -} - -button.btn, -input[type="submit"].btn { - *padding-top: 3px; - *padding-bottom: 3px; -} - -button.btn::-moz-focus-inner, -input[type="submit"].btn::-moz-focus-inner { - padding: 0; - border: 0; -} - -button.btn.btn-large, -input[type="submit"].btn.btn-large { - *padding-top: 7px; - *padding-bottom: 7px; -} - -button.btn.btn-small, -input[type="submit"].btn.btn-small { - *padding-top: 3px; - *padding-bottom: 3px; -} - -button.btn.btn-mini, -input[type="submit"].btn.btn-mini { - *padding-top: 1px; - *padding-bottom: 1px; -} - -.btn-link, -.btn-link:active, -.btn-link[disabled] { - background-color: transparent; - background-image: none; - -webkit-box-shadow: none; - -moz-box-shadow: none; - box-shadow: none; -} - -.btn-link { - color: #0088cc; - cursor: pointer; - border-color: transparent; - -webkit-border-radius: 0; - -moz-border-radius: 0; - border-radius: 0; -} - -.btn-link:hover, -.btn-link:focus { - color: #005580; - text-decoration: underline; - background-color: transparent; -} - -.btn-link[disabled]:hover, -.btn-link[disabled]:focus { - color: #333333; - text-decoration: none; -} - -.btn-group { - position: relative; - display: inline-block; - *display: inline; - *margin-left: .3em; - font-size: 0; - white-space: nowrap; - vertical-align: middle; - *zoom: 1; -} - -.btn-group:first-child { - *margin-left: 0; -} - -.btn-group + .btn-group { - margin-left: 5px; -} - -.btn-toolbar { - margin-top: 10px; - margin-bottom: 10px; - font-size: 0; -} - -.btn-toolbar > .btn + .btn, -.btn-toolbar > .btn-group + .btn, -.btn-toolbar > .btn + .btn-group { - margin-left: 5px; -} - -.btn-group > .btn { - position: relative; - -webkit-border-radius: 0; - -moz-border-radius: 0; - border-radius: 0; -} - -.btn-group > .btn + .btn { - margin-left: -1px; -} - -.btn-group > .btn, -.btn-group > .dropdown-menu, -.btn-group > .popover { - font-size: 14px; -} - -.btn-group > .btn-mini { - font-size: 10.5px; -} - -.btn-group > .btn-small { - font-size: 11.9px; -} - -.btn-group > .btn-large { - font-size: 17.5px; -} - -.btn-group > .btn:first-child { - margin-left: 0; - -webkit-border-bottom-left-radius: 4px; - border-bottom-left-radius: 4px; - -webkit-border-top-left-radius: 4px; - border-top-left-radius: 4px; - -moz-border-radius-bottomleft: 4px; - -moz-border-radius-topleft: 4px; -} - -.btn-group > .btn:last-child, -.btn-group > .dropdown-toggle { - -webkit-border-top-right-radius: 4px; - border-top-right-radius: 4px; - -webkit-border-bottom-right-radius: 4px; - border-bottom-right-radius: 4px; - -moz-border-radius-topright: 4px; - -moz-border-radius-bottomright: 4px; -} - -.btn-group > .btn.large:first-child { - margin-left: 0; - -webkit-border-bottom-left-radius: 6px; - border-bottom-left-radius: 6px; - -webkit-border-top-left-radius: 6px; - border-top-left-radius: 6px; - -moz-border-radius-bottomleft: 6px; - -moz-border-radius-topleft: 6px; -} - -.btn-group > .btn.large:last-child, -.btn-group > .large.dropdown-toggle { - -webkit-border-top-right-radius: 6px; - border-top-right-radius: 6px; - -webkit-border-bottom-right-radius: 6px; - border-bottom-right-radius: 6px; - -moz-border-radius-topright: 6px; - -moz-border-radius-bottomright: 6px; -} - -.btn-group > .btn:hover, -.btn-group > .btn:focus, -.btn-group > .btn:active, -.btn-group > .btn.active { - z-index: 2; -} - -.btn-group .dropdown-toggle:active, -.btn-group.open .dropdown-toggle { - outline: 0; -} - -.btn-group > .btn + .dropdown-toggle { - *padding-top: 5px; - padding-right: 8px; - *padding-bottom: 5px; - padding-left: 8px; - -webkit-box-shadow: inset 1px 0 0 rgba(255, 255, 255, 0.125), inset 0 1px 0 rgba(255, 255, 255, 0.2), 0 1px 2px rgba(0, 0, 0, 0.05); - -moz-box-shadow: inset 1px 0 0 rgba(255, 255, 255, 0.125), inset 0 1px 0 rgba(255, 255, 255, 0.2), 0 1px 2px rgba(0, 0, 0, 0.05); - box-shadow: inset 1px 0 0 rgba(255, 255, 255, 0.125), inset 0 1px 0 rgba(255, 255, 255, 0.2), 0 1px 2px rgba(0, 0, 0, 0.05); -} - -.btn-group > .btn-mini + .dropdown-toggle { - *padding-top: 2px; - padding-right: 5px; - *padding-bottom: 2px; - padding-left: 5px; -} - -.btn-group > .btn-small + .dropdown-toggle { - *padding-top: 5px; - *padding-bottom: 4px; -} - -.btn-group > .btn-large + .dropdown-toggle { - *padding-top: 7px; - padding-right: 12px; - *padding-bottom: 7px; - padding-left: 12px; -} - -.btn-group.open .dropdown-toggle { - background-image: none; - -webkit-box-shadow: inset 0 2px 4px rgba(0, 0, 0, 0.15), 0 1px 2px rgba(0, 0, 0, 0.05); - -moz-box-shadow: inset 0 2px 4px rgba(0, 0, 0, 0.15), 0 1px 2px rgba(0, 0, 0, 0.05); - box-shadow: inset 0 2px 4px rgba(0, 0, 0, 0.15), 0 1px 2px rgba(0, 0, 0, 0.05); -} - -.btn-group.open .btn.dropdown-toggle { - background-color: #e6e6e6; -} - -.btn-group.open .btn-primary.dropdown-toggle { - background-color: #0044cc; -} - -.btn-group.open .btn-warning.dropdown-toggle { - background-color: #f89406; -} - -.btn-group.open .btn-danger.dropdown-toggle { - background-color: #bd362f; -} - -.btn-group.open .btn-success.dropdown-toggle { - background-color: #51a351; -} - -.btn-group.open .btn-info.dropdown-toggle { - background-color: #2f96b4; -} - -.btn-group.open .btn-inverse.dropdown-toggle { - background-color: #222222; -} - -.btn .caret { - margin-top: 8px; - margin-left: 0; -} - -.btn-large .caret { - margin-top: 6px; -} - -.btn-large .caret { - border-top-width: 5px; - border-right-width: 5px; - border-left-width: 5px; -} - -.btn-mini .caret, -.btn-small .caret { - margin-top: 8px; -} - -.dropup .btn-large .caret { - border-bottom-width: 5px; -} - -.btn-primary .caret, -.btn-warning .caret, -.btn-danger .caret, -.btn-info .caret, -.btn-success .caret, -.btn-inverse .caret { - border-top-color: #ffffff; - border-bottom-color: #ffffff; -} - -.btn-group-vertical { - display: inline-block; - *display: inline; - /* IE7 inline-block hack */ - - *zoom: 1; -} - -.btn-group-vertical > .btn { - display: block; - float: none; - max-width: 100%; - -webkit-border-radius: 0; - -moz-border-radius: 0; - border-radius: 0; -} - -.btn-group-vertical > .btn + .btn { - margin-top: -1px; - margin-left: 0; -} - -.btn-group-vertical > .btn:first-child { - -webkit-border-radius: 4px 4px 0 0; - -moz-border-radius: 4px 4px 0 0; - border-radius: 4px 4px 0 0; -} - -.btn-group-vertical > .btn:last-child { - -webkit-border-radius: 0 0 4px 4px; - -moz-border-radius: 0 0 4px 4px; - border-radius: 0 0 4px 4px; -} - -.btn-group-vertical > .btn-large:first-child { - -webkit-border-radius: 6px 6px 0 0; - -moz-border-radius: 6px 6px 0 0; - border-radius: 6px 6px 0 0; -} - -.btn-group-vertical > .btn-large:last-child { - -webkit-border-radius: 0 0 6px 6px; - -moz-border-radius: 0 0 6px 6px; - border-radius: 0 0 6px 6px; -} - -.alert { - padding: 8px 35px 8px 14px; - margin-bottom: 20px; - text-shadow: 0 1px 0 rgba(255, 255, 255, 0.5); - background-color: #fcf8e3; - border: 1px solid #fbeed5; - -webkit-border-radius: 4px; - -moz-border-radius: 4px; - border-radius: 4px; -} - -.alert, -.alert h4 { - color: #c09853; -} - -.alert h4 { - margin: 0; -} - -.alert .close { - position: relative; - top: -2px; - right: -21px; - line-height: 20px; -} - -.alert-success { - color: #468847; - background-color: #dff0d8; - border-color: #d6e9c6; -} - -.alert-success h4 { - color: #468847; -} - -.alert-danger, -.alert-error { - color: #b94a48; - background-color: #f2dede; - border-color: #eed3d7; -} - -.alert-danger h4, -.alert-error h4 { - color: #b94a48; -} - -.alert-info { - color: #3a87ad; - background-color: #d9edf7; - border-color: #bce8f1; -} - -.alert-info h4 { - color: #3a87ad; -} - -.alert-block { - padding-top: 14px; - padding-bottom: 14px; -} - -.alert-block > p, -.alert-block > ul { - margin-bottom: 0; -} - -.alert-block p + p { - margin-top: 5px; -} - -.nav { - margin-bottom: 20px; - margin-left: 0; - list-style: none; -} - -.nav > li > a { - display: block; -} - -.nav > li > a:hover, -.nav > li > a:focus { - text-decoration: none; - background-color: #eeeeee; -} - -.nav > li > a > img { - max-width: none; -} - -.nav > .pull-right { - float: right; -} - -.nav-header { - display: block; - padding: 3px 15px; - font-size: 11px; - font-weight: bold; - line-height: 20px; - color: #999999; - text-shadow: 0 1px 0 rgba(255, 255, 255, 0.5); - text-transform: uppercase; -} - -.nav li + .nav-header { - margin-top: 9px; -} - -.nav-list { - padding-right: 15px; - padding-left: 15px; - margin-bottom: 0; -} - -.nav-list > li > a, -.nav-list .nav-header { - margin-right: -15px; - margin-left: -15px; - text-shadow: 0 1px 0 rgba(255, 255, 255, 0.5); -} - -.nav-list > li > a { - padding: 3px 15px; -} - -.nav-list > .active > a, -.nav-list > .active > a:hover, -.nav-list > .active > a:focus { - color: #ffffff; - text-shadow: 0 -1px 0 rgba(0, 0, 0, 0.2); - background-color: #0088cc; -} - -.nav-list [class^="icon-"], -.nav-list [class*=" icon-"] { - margin-right: 2px; -} - -.nav-list .divider { - *width: 100%; - height: 1px; - margin: 9px 1px; - *margin: -5px 0 5px; - overflow: hidden; - background-color: #e5e5e5; - border-bottom: 1px solid #ffffff; -} - -.nav-tabs, -.nav-pills { - *zoom: 1; -} - -.nav-tabs:before, -.nav-pills:before, -.nav-tabs:after, -.nav-pills:after { - display: table; - line-height: 0; - content: ""; -} - -.nav-tabs:after, -.nav-pills:after { - clear: both; -} - -.nav-tabs > li, -.nav-pills > li { - float: left; -} - -.nav-tabs > li > a, -.nav-pills > li > a { - padding-right: 12px; - padding-left: 12px; - margin-right: 2px; - line-height: 14px; -} - -.nav-tabs { - border-bottom: 1px solid #ddd; -} - -.nav-tabs > li { - margin-bottom: -1px; -} - -.nav-tabs > li > a { - padding-top: 8px; - padding-bottom: 8px; - line-height: 20px; - border: 1px solid transparent; - -webkit-border-radius: 4px 4px 0 0; - -moz-border-radius: 4px 4px 0 0; - border-radius: 4px 4px 0 0; -} - -.nav-tabs > li > a:hover, -.nav-tabs > li > a:focus { - border-color: #eeeeee #eeeeee #dddddd; -} - -.nav-tabs > .active > a, -.nav-tabs > .active > a:hover, -.nav-tabs > .active > a:focus { - color: #555555; - cursor: default; - background-color: #ffffff; - border: 1px solid #ddd; - border-bottom-color: transparent; -} - -.nav-pills > li > a { - padding-top: 8px; - padding-bottom: 8px; - margin-top: 2px; - margin-bottom: 2px; - -webkit-border-radius: 5px; - -moz-border-radius: 5px; - border-radius: 5px; -} - -.nav-pills > .active > a, -.nav-pills > .active > a:hover, -.nav-pills > .active > a:focus { - color: #ffffff; - background-color: #0088cc; -} - -.nav-stacked > li { - float: none; -} - -.nav-stacked > li > a { - margin-right: 0; -} - -.nav-tabs.nav-stacked { - border-bottom: 0; -} - -.nav-tabs.nav-stacked > li > a { - border: 1px solid #ddd; - -webkit-border-radius: 0; - -moz-border-radius: 0; - border-radius: 0; -} - -.nav-tabs.nav-stacked > li:first-child > a { - -webkit-border-top-right-radius: 4px; - border-top-right-radius: 4px; - -webkit-border-top-left-radius: 4px; - border-top-left-radius: 4px; - -moz-border-radius-topright: 4px; - -moz-border-radius-topleft: 4px; -} - -.nav-tabs.nav-stacked > li:last-child > a { - -webkit-border-bottom-right-radius: 4px; - border-bottom-right-radius: 4px; - -webkit-border-bottom-left-radius: 4px; - border-bottom-left-radius: 4px; - -moz-border-radius-bottomright: 4px; - -moz-border-radius-bottomleft: 4px; -} - -.nav-tabs.nav-stacked > li > a:hover, -.nav-tabs.nav-stacked > li > a:focus { - z-index: 2; - border-color: #ddd; -} - -.nav-pills.nav-stacked > li > a { - margin-bottom: 3px; -} - -.nav-pills.nav-stacked > li:last-child > a { - margin-bottom: 1px; -} - -.nav-tabs .dropdown-menu { - -webkit-border-radius: 0 0 6px 6px; - -moz-border-radius: 0 0 6px 6px; - border-radius: 0 0 6px 6px; -} - -.nav-pills .dropdown-menu { - -webkit-border-radius: 6px; - -moz-border-radius: 6px; - border-radius: 6px; -} - -.nav .dropdown-toggle .caret { - margin-top: 6px; - border-top-color: #0088cc; - border-bottom-color: #0088cc; -} - -.nav .dropdown-toggle:hover .caret, -.nav .dropdown-toggle:focus .caret { - border-top-color: #005580; - border-bottom-color: #005580; -} - -/* move down carets for tabs */ - -.nav-tabs .dropdown-toggle .caret { - margin-top: 8px; -} - -.nav .active .dropdown-toggle .caret { - border-top-color: #fff; - border-bottom-color: #fff; -} - -.nav-tabs .active .dropdown-toggle .caret { - border-top-color: #555555; - border-bottom-color: #555555; -} - -.nav > .dropdown.active > a:hover, -.nav > .dropdown.active > a:focus { - cursor: pointer; -} - -.nav-tabs .open .dropdown-toggle, -.nav-pills .open .dropdown-toggle, -.nav > li.dropdown.open.active > a:hover, -.nav > li.dropdown.open.active > a:focus { - color: #ffffff; - background-color: #999999; - border-color: #999999; -} - -.nav li.dropdown.open .caret, -.nav li.dropdown.open.active .caret, -.nav li.dropdown.open a:hover .caret, -.nav li.dropdown.open a:focus .caret { - border-top-color: #ffffff; - border-bottom-color: #ffffff; - opacity: 1; - filter: alpha(opacity=100); -} - -.tabs-stacked .open > a:hover, -.tabs-stacked .open > a:focus { - border-color: #999999; -} - -.tabbable { - *zoom: 1; -} - -.tabbable:before, -.tabbable:after { - display: table; - line-height: 0; - content: ""; -} - -.tabbable:after { - clear: both; -} - -.tab-content { - overflow: auto; -} - -.tabs-below > .nav-tabs, -.tabs-right > .nav-tabs, -.tabs-left > .nav-tabs { - border-bottom: 0; -} - -.tab-content > .tab-pane, -.pill-content > .pill-pane { - display: none; -} - -.tab-content > .active, -.pill-content > .active { - display: block; -} - -.tabs-below > .nav-tabs { - border-top: 1px solid #ddd; -} - -.tabs-below > .nav-tabs > li { - margin-top: -1px; - margin-bottom: 0; -} - -.tabs-below > .nav-tabs > li > a { - -webkit-border-radius: 0 0 4px 4px; - -moz-border-radius: 0 0 4px 4px; - border-radius: 0 0 4px 4px; -} - -.tabs-below > .nav-tabs > li > a:hover, -.tabs-below > .nav-tabs > li > a:focus { - border-top-color: #ddd; - border-bottom-color: transparent; -} - -.tabs-below > .nav-tabs > .active > a, -.tabs-below > .nav-tabs > .active > a:hover, -.tabs-below > .nav-tabs > .active > a:focus { - border-color: transparent #ddd #ddd #ddd; -} - -.tabs-left > .nav-tabs > li, -.tabs-right > .nav-tabs > li { - float: none; -} - -.tabs-left > .nav-tabs > li > a, -.tabs-right > .nav-tabs > li > a { - min-width: 74px; - margin-right: 0; - margin-bottom: 3px; -} - -.tabs-left > .nav-tabs { - float: left; - margin-right: 19px; - border-right: 1px solid #ddd; -} - -.tabs-left > .nav-tabs > li > a { - margin-right: -1px; - -webkit-border-radius: 4px 0 0 4px; - -moz-border-radius: 4px 0 0 4px; - border-radius: 4px 0 0 4px; -} - -.tabs-left > .nav-tabs > li > a:hover, -.tabs-left > .nav-tabs > li > a:focus { - border-color: #eeeeee #dddddd #eeeeee #eeeeee; -} - -.tabs-left > .nav-tabs .active > a, -.tabs-left > .nav-tabs .active > a:hover, -.tabs-left > .nav-tabs .active > a:focus { - border-color: #ddd transparent #ddd #ddd; - *border-right-color: #ffffff; -} - -.tabs-right > .nav-tabs { - float: right; - margin-left: 19px; - border-left: 1px solid #ddd; -} - -.tabs-right > .nav-tabs > li > a { - margin-left: -1px; - -webkit-border-radius: 0 4px 4px 0; - -moz-border-radius: 0 4px 4px 0; - border-radius: 0 4px 4px 0; -} - -.tabs-right > .nav-tabs > li > a:hover, -.tabs-right > .nav-tabs > li > a:focus { - border-color: #eeeeee #eeeeee #eeeeee #dddddd; -} - -.tabs-right > .nav-tabs .active > a, -.tabs-right > .nav-tabs .active > a:hover, -.tabs-right > .nav-tabs .active > a:focus { - border-color: #ddd #ddd #ddd transparent; - *border-left-color: #ffffff; -} - -.nav > .disabled > a { - color: #999999; -} - -.nav > .disabled > a:hover, -.nav > .disabled > a:focus { - text-decoration: none; - cursor: default; - background-color: transparent; -} - -.navbar { - *position: relative; - *z-index: 2; - margin-bottom: 20px; - overflow: visible; -} - -.navbar-inner { - min-height: 40px; - padding-right: 20px; - padding-left: 20px; - background-color: #fafafa; - background-image: -moz-linear-gradient(top, #ffffff, #f2f2f2); - background-image: -webkit-gradient(linear, 0 0, 0 100%, from(#ffffff), to(#f2f2f2)); - background-image: -webkit-linear-gradient(top, #ffffff, #f2f2f2); - background-image: -o-linear-gradient(top, #ffffff, #f2f2f2); - background-image: linear-gradient(to bottom, #ffffff, #f2f2f2); - background-repeat: repeat-x; - border: 1px solid #d4d4d4; - -webkit-border-radius: 4px; - -moz-border-radius: 4px; - border-radius: 4px; - filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#ffffffff', endColorstr='#fff2f2f2', GradientType=0); - *zoom: 1; - -webkit-box-shadow: 0 1px 4px rgba(0, 0, 0, 0.065); - -moz-box-shadow: 0 1px 4px rgba(0, 0, 0, 0.065); - box-shadow: 0 1px 4px rgba(0, 0, 0, 0.065); -} - -.navbar-inner:before, -.navbar-inner:after { - display: table; - line-height: 0; - content: ""; -} - -.navbar-inner:after { - clear: both; -} - -.navbar .container { - width: auto; -} - -.nav-collapse.collapse { - height: auto; - overflow: visible; -} - -.navbar .brand { - display: block; - float: left; - padding: 10px 20px 10px; - margin-left: -20px; - font-size: 20px; - font-weight: 200; - color: #777777; - text-shadow: 0 1px 0 #ffffff; -} - -.navbar .brand:hover, -.navbar .brand:focus { - text-decoration: none; -} - -.navbar-text { - margin-bottom: 0; - line-height: 40px; - color: #777777; -} - -.navbar-link { - color: #777777; -} - -.navbar-link:hover, -.navbar-link:focus { - color: #333333; -} - -.navbar .divider-vertical { - height: 40px; - margin: 0 9px; - border-right: 1px solid #ffffff; - border-left: 1px solid #f2f2f2; -} - -.navbar .btn, -.navbar .btn-group { - margin-top: 5px; -} - -.navbar .btn-group .btn, -.navbar .input-prepend .btn, -.navbar .input-append .btn, -.navbar .input-prepend .btn-group, -.navbar .input-append .btn-group { - margin-top: 0; -} - -.navbar-form { - margin-bottom: 0; - *zoom: 1; -} - -.navbar-form:before, -.navbar-form:after { - display: table; - line-height: 0; - content: ""; -} - -.navbar-form:after { - clear: both; -} - -.navbar-form input, -.navbar-form select, -.navbar-form .radio, -.navbar-form .checkbox { - margin-top: 5px; -} - -.navbar-form input, -.navbar-form select, -.navbar-form .btn { - display: inline-block; - margin-bottom: 0; -} - -.navbar-form input[type="image"], -.navbar-form input[type="checkbox"], -.navbar-form input[type="radio"] { - margin-top: 3px; -} - -.navbar-form .input-append, -.navbar-form .input-prepend { - margin-top: 5px; - white-space: nowrap; -} - -.navbar-form .input-append input, -.navbar-form .input-prepend input { - margin-top: 0; -} - -.navbar-search { - position: relative; - float: left; - margin-top: 5px; - margin-bottom: 0; -} - -.navbar-search .search-query { - padding: 4px 14px; - margin-bottom: 0; - font-family: "Helvetica Neue", Helvetica, Arial, sans-serif; - font-size: 13px; - font-weight: normal; - line-height: 1; - -webkit-border-radius: 15px; - -moz-border-radius: 15px; - border-radius: 15px; -} - -.navbar-static-top { - position: static; - margin-bottom: 0; -} - -.navbar-static-top .navbar-inner { - -webkit-border-radius: 0; - -moz-border-radius: 0; - border-radius: 0; -} - -.navbar-fixed-top, -.navbar-fixed-bottom { - position: fixed; - right: 0; - left: 0; - z-index: 1030; - margin-bottom: 0; -} - -.navbar-fixed-top .navbar-inner, -.navbar-static-top .navbar-inner { - border-width: 0 0 1px; -} - -.navbar-fixed-bottom .navbar-inner { - border-width: 1px 0 0; -} - -.navbar-fixed-top .navbar-inner, -.navbar-fixed-bottom .navbar-inner { - padding-right: 0; - padding-left: 0; - -webkit-border-radius: 0; - -moz-border-radius: 0; - border-radius: 0; -} - -.navbar-static-top .container, -.navbar-fixed-top .container, -.navbar-fixed-bottom .container { - width: 940px; -} - -.navbar-fixed-top { - top: 0; -} - -.navbar-fixed-top .navbar-inner, -.navbar-static-top .navbar-inner { - -webkit-box-shadow: 0 1px 10px rgba(0, 0, 0, 0.1); - -moz-box-shadow: 0 1px 10px rgba(0, 0, 0, 0.1); - box-shadow: 0 1px 10px rgba(0, 0, 0, 0.1); -} - -.navbar-fixed-bottom { - bottom: 0; -} - -.navbar-fixed-bottom .navbar-inner { - -webkit-box-shadow: 0 -1px 10px rgba(0, 0, 0, 0.1); - -moz-box-shadow: 0 -1px 10px rgba(0, 0, 0, 0.1); - box-shadow: 0 -1px 10px rgba(0, 0, 0, 0.1); -} - -.navbar .nav { - position: relative; - left: 0; - display: block; - float: left; - margin: 0 10px 0 0; -} - -.navbar .nav.pull-right { - float: right; - margin-right: 0; -} - -.navbar .nav > li { - float: left; -} - -.navbar .nav > li > a { - float: none; - padding: 10px 15px 10px; - color: #777777; - text-decoration: none; - text-shadow: 0 1px 0 #ffffff; -} - -.navbar .nav .dropdown-toggle .caret { - margin-top: 8px; -} - -.navbar .nav > li > a:focus, -.navbar .nav > li > a:hover { - color: #333333; - text-decoration: none; - background-color: transparent; -} - -.navbar .nav > .active > a, -.navbar .nav > .active > a:hover, -.navbar .nav > .active > a:focus { - color: #555555; - text-decoration: none; - background-color: #e5e5e5; - -webkit-box-shadow: inset 0 3px 8px rgba(0, 0, 0, 0.125); - -moz-box-shadow: inset 0 3px 8px rgba(0, 0, 0, 0.125); - box-shadow: inset 0 3px 8px rgba(0, 0, 0, 0.125); -} - -.navbar .btn-navbar { - display: none; - float: right; - padding: 7px 10px; - margin-right: 5px; - margin-left: 5px; - color: #ffffff; - text-shadow: 0 -1px 0 rgba(0, 0, 0, 0.25); - background-color: #ededed; - *background-color: #e5e5e5; - background-image: -moz-linear-gradient(top, #f2f2f2, #e5e5e5); - background-image: -webkit-gradient(linear, 0 0, 0 100%, from(#f2f2f2), to(#e5e5e5)); - background-image: -webkit-linear-gradient(top, #f2f2f2, #e5e5e5); - background-image: -o-linear-gradient(top, #f2f2f2, #e5e5e5); - background-image: linear-gradient(to bottom, #f2f2f2, #e5e5e5); - background-repeat: repeat-x; - border-color: #e5e5e5 #e5e5e5 #bfbfbf; - border-color: rgba(0, 0, 0, 0.1) rgba(0, 0, 0, 0.1) rgba(0, 0, 0, 0.25); - filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#fff2f2f2', endColorstr='#ffe5e5e5', GradientType=0); - filter: progid:DXImageTransform.Microsoft.gradient(enabled=false); - -webkit-box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.1), 0 1px 0 rgba(255, 255, 255, 0.075); - -moz-box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.1), 0 1px 0 rgba(255, 255, 255, 0.075); - box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.1), 0 1px 0 rgba(255, 255, 255, 0.075); -} - -.navbar .btn-navbar:hover, -.navbar .btn-navbar:focus, -.navbar .btn-navbar:active, -.navbar .btn-navbar.active, -.navbar .btn-navbar.disabled, -.navbar .btn-navbar[disabled] { - color: #ffffff; - background-color: #e5e5e5; - *background-color: #d9d9d9; -} - -.navbar .btn-navbar:active, -.navbar .btn-navbar.active { - background-color: #cccccc \9; -} - -.navbar .btn-navbar .icon-bar { - display: block; - width: 18px; - height: 2px; - background-color: #f5f5f5; - -webkit-border-radius: 1px; - -moz-border-radius: 1px; - border-radius: 1px; - -webkit-box-shadow: 0 1px 0 rgba(0, 0, 0, 0.25); - -moz-box-shadow: 0 1px 0 rgba(0, 0, 0, 0.25); - box-shadow: 0 1px 0 rgba(0, 0, 0, 0.25); -} - -.btn-navbar .icon-bar + .icon-bar { - margin-top: 3px; -} - -.navbar .nav > li > .dropdown-menu:before { - position: absolute; - top: -7px; - left: 9px; - display: inline-block; - border-right: 7px solid transparent; - border-bottom: 7px solid #ccc; - border-left: 7px solid transparent; - border-bottom-color: rgba(0, 0, 0, 0.2); - content: ''; -} - -.navbar .nav > li > .dropdown-menu:after { - position: absolute; - top: -6px; - left: 10px; - display: inline-block; - border-right: 6px solid transparent; - border-bottom: 6px solid #ffffff; - border-left: 6px solid transparent; - content: ''; -} - -.navbar-fixed-bottom .nav > li > .dropdown-menu:before { - top: auto; - bottom: -7px; - border-top: 7px solid #ccc; - border-bottom: 0; - border-top-color: rgba(0, 0, 0, 0.2); -} - -.navbar-fixed-bottom .nav > li > .dropdown-menu:after { - top: auto; - bottom: -6px; - border-top: 6px solid #ffffff; - border-bottom: 0; -} - -.navbar .nav li.dropdown > a:hover .caret, -.navbar .nav li.dropdown > a:focus .caret { - border-top-color: #333333; - border-bottom-color: #333333; -} - -.navbar .nav li.dropdown.open > .dropdown-toggle, -.navbar .nav li.dropdown.active > .dropdown-toggle, -.navbar .nav li.dropdown.open.active > .dropdown-toggle { - color: #555555; - background-color: #e5e5e5; -} - -.navbar .nav li.dropdown > .dropdown-toggle .caret { - border-top-color: #777777; - border-bottom-color: #777777; -} - -.navbar .nav li.dropdown.open > .dropdown-toggle .caret, -.navbar .nav li.dropdown.active > .dropdown-toggle .caret, -.navbar .nav li.dropdown.open.active > .dropdown-toggle .caret { - border-top-color: #555555; - border-bottom-color: #555555; -} - -.navbar .pull-right > li > .dropdown-menu, -.navbar .nav > li > .dropdown-menu.pull-right { - right: 0; - left: auto; -} - -.navbar .pull-right > li > .dropdown-menu:before, -.navbar .nav > li > .dropdown-menu.pull-right:before { - right: 12px; - left: auto; -} - -.navbar .pull-right > li > .dropdown-menu:after, -.navbar .nav > li > .dropdown-menu.pull-right:after { - right: 13px; - left: auto; -} - -.navbar .pull-right > li > .dropdown-menu .dropdown-menu, -.navbar .nav > li > .dropdown-menu.pull-right .dropdown-menu { - right: 100%; - left: auto; - margin-right: -1px; - margin-left: 0; - -webkit-border-radius: 6px 0 6px 6px; - -moz-border-radius: 6px 0 6px 6px; - border-radius: 6px 0 6px 6px; -} - -.navbar-inverse .navbar-inner { - background-color: #1b1b1b; - background-image: -moz-linear-gradient(top, #222222, #111111); - background-image: -webkit-gradient(linear, 0 0, 0 100%, from(#222222), to(#111111)); - background-image: -webkit-linear-gradient(top, #222222, #111111); - background-image: -o-linear-gradient(top, #222222, #111111); - background-image: linear-gradient(to bottom, #222222, #111111); - background-repeat: repeat-x; - border-color: #252525; - filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#ff222222', endColorstr='#ff111111', GradientType=0); -} - -.navbar-inverse .brand, -.navbar-inverse .nav > li > a { - color: #999999; - text-shadow: 0 -1px 0 rgba(0, 0, 0, 0.25); -} - -.navbar-inverse .brand:hover, -.navbar-inverse .nav > li > a:hover, -.navbar-inverse .brand:focus, -.navbar-inverse .nav > li > a:focus { - color: #ffffff; -} - -.navbar-inverse .brand { - color: #999999; -} - -.navbar-inverse .navbar-text { - color: #999999; -} - -.navbar-inverse .nav > li > a:focus, -.navbar-inverse .nav > li > a:hover { - color: #ffffff; - background-color: transparent; -} - -.navbar-inverse .nav .active > a, -.navbar-inverse .nav .active > a:hover, -.navbar-inverse .nav .active > a:focus { - color: #ffffff; - background-color: #111111; -} - -.navbar-inverse .navbar-link { - color: #999999; -} - -.navbar-inverse .navbar-link:hover, -.navbar-inverse .navbar-link:focus { - color: #ffffff; -} - -.navbar-inverse .divider-vertical { - border-right-color: #222222; - border-left-color: #111111; -} - -.navbar-inverse .nav li.dropdown.open > .dropdown-toggle, -.navbar-inverse .nav li.dropdown.active > .dropdown-toggle, -.navbar-inverse .nav li.dropdown.open.active > .dropdown-toggle { - color: #ffffff; - background-color: #111111; -} - -.navbar-inverse .nav li.dropdown > a:hover .caret, -.navbar-inverse .nav li.dropdown > a:focus .caret { - border-top-color: #ffffff; - border-bottom-color: #ffffff; -} - -.navbar-inverse .nav li.dropdown > .dropdown-toggle .caret { - border-top-color: #999999; - border-bottom-color: #999999; -} - -.navbar-inverse .nav li.dropdown.open > .dropdown-toggle .caret, -.navbar-inverse .nav li.dropdown.active > .dropdown-toggle .caret, -.navbar-inverse .nav li.dropdown.open.active > .dropdown-toggle .caret { - border-top-color: #ffffff; - border-bottom-color: #ffffff; -} - -.navbar-inverse .navbar-search .search-query { - color: #ffffff; - background-color: #515151; - border-color: #111111; - -webkit-box-shadow: inset 0 1px 2px rgba(0, 0, 0, 0.1), 0 1px 0 rgba(255, 255, 255, 0.15); - -moz-box-shadow: inset 0 1px 2px rgba(0, 0, 0, 0.1), 0 1px 0 rgba(255, 255, 255, 0.15); - box-shadow: inset 0 1px 2px rgba(0, 0, 0, 0.1), 0 1px 0 rgba(255, 255, 255, 0.15); - -webkit-transition: none; - -moz-transition: none; - -o-transition: none; - transition: none; -} - -.navbar-inverse .navbar-search .search-query:-moz-placeholder { - color: #cccccc; -} - -.navbar-inverse .navbar-search .search-query:-ms-input-placeholder { - color: #cccccc; -} - -.navbar-inverse .navbar-search .search-query::-webkit-input-placeholder { - color: #cccccc; -} - -.navbar-inverse .navbar-search .search-query:focus, -.navbar-inverse .navbar-search .search-query.focused { - padding: 5px 15px; - color: #333333; - text-shadow: 0 1px 0 #ffffff; - background-color: #ffffff; - border: 0; - outline: 0; - -webkit-box-shadow: 0 0 3px rgba(0, 0, 0, 0.15); - -moz-box-shadow: 0 0 3px rgba(0, 0, 0, 0.15); - box-shadow: 0 0 3px rgba(0, 0, 0, 0.15); -} - -.navbar-inverse .btn-navbar { - color: #ffffff; - text-shadow: 0 -1px 0 rgba(0, 0, 0, 0.25); - background-color: #0e0e0e; - *background-color: #040404; - background-image: -moz-linear-gradient(top, #151515, #040404); - background-image: -webkit-gradient(linear, 0 0, 0 100%, from(#151515), to(#040404)); - background-image: -webkit-linear-gradient(top, #151515, #040404); - background-image: -o-linear-gradient(top, #151515, #040404); - background-image: linear-gradient(to bottom, #151515, #040404); - background-repeat: repeat-x; - border-color: #040404 #040404 #000000; - border-color: rgba(0, 0, 0, 0.1) rgba(0, 0, 0, 0.1) rgba(0, 0, 0, 0.25); - filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#ff151515', endColorstr='#ff040404', GradientType=0); - filter: progid:DXImageTransform.Microsoft.gradient(enabled=false); -} - -.navbar-inverse .btn-navbar:hover, -.navbar-inverse .btn-navbar:focus, -.navbar-inverse .btn-navbar:active, -.navbar-inverse .btn-navbar.active, -.navbar-inverse .btn-navbar.disabled, -.navbar-inverse .btn-navbar[disabled] { - color: #ffffff; - background-color: #040404; - *background-color: #000000; -} - -.navbar-inverse .btn-navbar:active, -.navbar-inverse .btn-navbar.active { - background-color: #000000 \9; -} - -.breadcrumb { - padding: 8px 15px; - margin: 0 0 20px; - list-style: none; - background-color: #f5f5f5; - -webkit-border-radius: 4px; - -moz-border-radius: 4px; - border-radius: 4px; -} - -.breadcrumb > li { - display: inline-block; - *display: inline; - text-shadow: 0 1px 0 #ffffff; - *zoom: 1; -} - -.breadcrumb > li > .divider { - padding: 0 5px; - color: #ccc; -} - -.breadcrumb > .active { - color: #999999; -} - -.pagination { - margin: 20px 0; -} - -.pagination ul { - display: inline-block; - *display: inline; - margin-bottom: 0; - margin-left: 0; - -webkit-border-radius: 4px; - -moz-border-radius: 4px; - border-radius: 4px; - *zoom: 1; - -webkit-box-shadow: 0 1px 2px rgba(0, 0, 0, 0.05); - -moz-box-shadow: 0 1px 2px rgba(0, 0, 0, 0.05); - box-shadow: 0 1px 2px rgba(0, 0, 0, 0.05); -} - -.pagination ul > li { - display: inline; -} - -.pagination ul > li > a, -.pagination ul > li > span { - float: left; - padding: 4px 12px; - line-height: 20px; - text-decoration: none; - background-color: #ffffff; - border: 1px solid #dddddd; - border-left-width: 0; -} - -.pagination ul > li > a:hover, -.pagination ul > li > a:focus, -.pagination ul > .active > a, -.pagination ul > .active > span { - background-color: #f5f5f5; -} - -.pagination ul > .active > a, -.pagination ul > .active > span { - color: #999999; - cursor: default; -} - -.pagination ul > .disabled > span, -.pagination ul > .disabled > a, -.pagination ul > .disabled > a:hover, -.pagination ul > .disabled > a:focus { - color: #999999; - cursor: default; - background-color: transparent; -} - -.pagination ul > li:first-child > a, -.pagination ul > li:first-child > span { - border-left-width: 1px; - -webkit-border-bottom-left-radius: 4px; - border-bottom-left-radius: 4px; - -webkit-border-top-left-radius: 4px; - border-top-left-radius: 4px; - -moz-border-radius-bottomleft: 4px; - -moz-border-radius-topleft: 4px; -} - -.pagination ul > li:last-child > a, -.pagination ul > li:last-child > span { - -webkit-border-top-right-radius: 4px; - border-top-right-radius: 4px; - -webkit-border-bottom-right-radius: 4px; - border-bottom-right-radius: 4px; - -moz-border-radius-topright: 4px; - -moz-border-radius-bottomright: 4px; -} - -.pagination-centered { - text-align: center; -} - -.pagination-right { - text-align: right; -} - -.pagination-large ul > li > a, -.pagination-large ul > li > span { - padding: 11px 19px; - font-size: 17.5px; -} - -.pagination-large ul > li:first-child > a, -.pagination-large ul > li:first-child > span { - -webkit-border-bottom-left-radius: 6px; - border-bottom-left-radius: 6px; - -webkit-border-top-left-radius: 6px; - border-top-left-radius: 6px; - -moz-border-radius-bottomleft: 6px; - -moz-border-radius-topleft: 6px; -} - -.pagination-large ul > li:last-child > a, -.pagination-large ul > li:last-child > span { - -webkit-border-top-right-radius: 6px; - border-top-right-radius: 6px; - -webkit-border-bottom-right-radius: 6px; - border-bottom-right-radius: 6px; - -moz-border-radius-topright: 6px; - -moz-border-radius-bottomright: 6px; -} - -.pagination-mini ul > li:first-child > a, -.pagination-small ul > li:first-child > a, -.pagination-mini ul > li:first-child > span, -.pagination-small ul > li:first-child > span { - -webkit-border-bottom-left-radius: 3px; - border-bottom-left-radius: 3px; - -webkit-border-top-left-radius: 3px; - border-top-left-radius: 3px; - -moz-border-radius-bottomleft: 3px; - -moz-border-radius-topleft: 3px; -} - -.pagination-mini ul > li:last-child > a, -.pagination-small ul > li:last-child > a, -.pagination-mini ul > li:last-child > span, -.pagination-small ul > li:last-child > span { - -webkit-border-top-right-radius: 3px; - border-top-right-radius: 3px; - -webkit-border-bottom-right-radius: 3px; - border-bottom-right-radius: 3px; - -moz-border-radius-topright: 3px; - -moz-border-radius-bottomright: 3px; -} - -.pagination-small ul > li > a, -.pagination-small ul > li > span { - padding: 2px 10px; - font-size: 11.9px; -} - -.pagination-mini ul > li > a, -.pagination-mini ul > li > span { - padding: 0 6px; - font-size: 10.5px; -} - -.pager { - margin: 20px 0; - text-align: center; - list-style: none; - *zoom: 1; -} - -.pager:before, -.pager:after { - display: table; - line-height: 0; - content: ""; -} - -.pager:after { - clear: both; -} - -.pager li { - display: inline; -} - -.pager li > a, -.pager li > span { - display: inline-block; - padding: 5px 14px; - background-color: #fff; - border: 1px solid #ddd; - -webkit-border-radius: 15px; - -moz-border-radius: 15px; - border-radius: 15px; -} - -.pager li > a:hover, -.pager li > a:focus { - text-decoration: none; - background-color: #f5f5f5; -} - -.pager .next > a, -.pager .next > span { - float: right; -} - -.pager .previous > a, -.pager .previous > span { - float: left; -} - -.pager .disabled > a, -.pager .disabled > a:hover, -.pager .disabled > a:focus, -.pager .disabled > span { - color: #999999; - cursor: default; - background-color: #fff; -} - -.modal-backdrop { - position: fixed; - top: 0; - right: 0; - bottom: 0; - left: 0; - z-index: 1040; - background-color: #000000; -} - -.modal-backdrop.fade { - opacity: 0; -} - -.modal-backdrop, -.modal-backdrop.fade.in { - opacity: 0.8; - filter: alpha(opacity=80); -} - -.modal { - position: fixed; - top: 10%; - left: 50%; - z-index: 1050; - width: 560px; - margin-left: -280px; - background-color: #ffffff; - border: 1px solid #999; - border: 1px solid rgba(0, 0, 0, 0.3); - *border: 1px solid #999; - -webkit-border-radius: 6px; - -moz-border-radius: 6px; - border-radius: 6px; - outline: none; - -webkit-box-shadow: 0 3px 7px rgba(0, 0, 0, 0.3); - -moz-box-shadow: 0 3px 7px rgba(0, 0, 0, 0.3); - box-shadow: 0 3px 7px rgba(0, 0, 0, 0.3); - -webkit-background-clip: padding-box; - -moz-background-clip: padding-box; - background-clip: padding-box; -} - -.modal.fade { - top: -25%; - -webkit-transition: opacity 0.3s linear, top 0.3s ease-out; - -moz-transition: opacity 0.3s linear, top 0.3s ease-out; - -o-transition: opacity 0.3s linear, top 0.3s ease-out; - transition: opacity 0.3s linear, top 0.3s ease-out; -} - -.modal.fade.in { - top: 10%; -} - -.modal-header { - padding: 9px 15px; - border-bottom: 1px solid #eee; -} - -.modal-header .close { - margin-top: 2px; -} - -.modal-header h3 { - margin: 0; - line-height: 30px; -} - -.modal-body { - position: relative; - max-height: 400px; - padding: 15px; - overflow-y: auto; -} - -.modal-form { - margin-bottom: 0; -} - -.modal-footer { - padding: 14px 15px 15px; - margin-bottom: 0; - text-align: right; - background-color: #f5f5f5; - border-top: 1px solid #ddd; - -webkit-border-radius: 0 0 6px 6px; - -moz-border-radius: 0 0 6px 6px; - border-radius: 0 0 6px 6px; - *zoom: 1; - -webkit-box-shadow: inset 0 1px 0 #ffffff; - -moz-box-shadow: inset 0 1px 0 #ffffff; - box-shadow: inset 0 1px 0 #ffffff; -} - -.modal-footer:before, -.modal-footer:after { - display: table; - line-height: 0; - content: ""; -} - -.modal-footer:after { - clear: both; -} - -.modal-footer .btn + .btn { - margin-bottom: 0; - margin-left: 5px; -} - -.modal-footer .btn-group .btn + .btn { - margin-left: -1px; -} - -.modal-footer .btn-block + .btn-block { - margin-left: 0; -} - -.tooltip { - position: absolute; - z-index: 1030; - display: block; - font-size: 11px; - line-height: 1.4; - opacity: 0; - filter: alpha(opacity=0); - visibility: visible; -} - -.tooltip.in { - opacity: 0.8; - filter: alpha(opacity=80); -} - -.tooltip.top { - padding: 5px 0; - margin-top: -3px; -} - -.tooltip.right { - padding: 0 5px; - margin-left: 3px; -} - -.tooltip.bottom { - padding: 5px 0; - margin-top: 3px; -} - -.tooltip.left { - padding: 0 5px; - margin-left: -3px; -} - -.tooltip-inner { - max-width: 200px; - padding: 8px; - color: #ffffff; - text-align: center; - text-decoration: none; - background-color: #000000; - -webkit-border-radius: 4px; - -moz-border-radius: 4px; - border-radius: 4px; -} - -.tooltip-arrow { - position: absolute; - width: 0; - height: 0; - border-color: transparent; - border-style: solid; -} - -.tooltip.top .tooltip-arrow { - bottom: 0; - left: 50%; - margin-left: -5px; - border-top-color: #000000; - border-width: 5px 5px 0; -} - -.tooltip.right .tooltip-arrow { - top: 50%; - left: 0; - margin-top: -5px; - border-right-color: #000000; - border-width: 5px 5px 5px 0; -} - -.tooltip.left .tooltip-arrow { - top: 50%; - right: 0; - margin-top: -5px; - border-left-color: #000000; - border-width: 5px 0 5px 5px; -} - -.tooltip.bottom .tooltip-arrow { - top: 0; - left: 50%; - margin-left: -5px; - border-bottom-color: #000000; - border-width: 0 5px 5px; -} - -.popover { - position: absolute; - top: 0; - left: 0; - z-index: 1010; - display: none; - max-width: 276px; - padding: 1px; - text-align: left; - white-space: normal; - background-color: #ffffff; - border: 1px solid #ccc; - border: 1px solid rgba(0, 0, 0, 0.2); - -webkit-border-radius: 6px; - -moz-border-radius: 6px; - border-radius: 6px; - -webkit-box-shadow: 0 5px 10px rgba(0, 0, 0, 0.2); - -moz-box-shadow: 0 5px 10px rgba(0, 0, 0, 0.2); - box-shadow: 0 5px 10px rgba(0, 0, 0, 0.2); - -webkit-background-clip: padding-box; - -moz-background-clip: padding; - background-clip: padding-box; -} - -.popover.top { - margin-top: -10px; -} - -.popover.right { - margin-left: 10px; -} - -.popover.bottom { - margin-top: 10px; -} - -.popover.left { - margin-left: -10px; -} - -.popover-title { - padding: 8px 14px; - margin: 0; - font-size: 14px; - font-weight: normal; - line-height: 18px; - background-color: #f7f7f7; - border-bottom: 1px solid #ebebeb; - -webkit-border-radius: 5px 5px 0 0; - -moz-border-radius: 5px 5px 0 0; - border-radius: 5px 5px 0 0; -} - -.popover-title:empty { - display: none; -} - -.popover-content { - padding: 9px 14px; -} - -.popover .arrow, -.popover .arrow:after { - position: absolute; - display: block; - width: 0; - height: 0; - border-color: transparent; - border-style: solid; -} - -.popover .arrow { - border-width: 11px; -} - -.popover .arrow:after { - border-width: 10px; - content: ""; -} - -.popover.top .arrow { - bottom: -11px; - left: 50%; - margin-left: -11px; - border-top-color: #999; - border-top-color: rgba(0, 0, 0, 0.25); - border-bottom-width: 0; -} - -.popover.top .arrow:after { - bottom: 1px; - margin-left: -10px; - border-top-color: #ffffff; - border-bottom-width: 0; -} - -.popover.right .arrow { - top: 50%; - left: -11px; - margin-top: -11px; - border-right-color: #999; - border-right-color: rgba(0, 0, 0, 0.25); - border-left-width: 0; -} - -.popover.right .arrow:after { - bottom: -10px; - left: 1px; - border-right-color: #ffffff; - border-left-width: 0; -} - -.popover.bottom .arrow { - top: -11px; - left: 50%; - margin-left: -11px; - border-bottom-color: #999; - border-bottom-color: rgba(0, 0, 0, 0.25); - border-top-width: 0; -} - -.popover.bottom .arrow:after { - top: 1px; - margin-left: -10px; - border-bottom-color: #ffffff; - border-top-width: 0; -} - -.popover.left .arrow { - top: 50%; - right: -11px; - margin-top: -11px; - border-left-color: #999; - border-left-color: rgba(0, 0, 0, 0.25); - border-right-width: 0; -} - -.popover.left .arrow:after { - right: 1px; - bottom: -10px; - border-left-color: #ffffff; - border-right-width: 0; -} - -.thumbnails { - margin-left: -20px; - list-style: none; - *zoom: 1; -} - -.thumbnails:before, -.thumbnails:after { - display: table; - line-height: 0; - content: ""; -} - -.thumbnails:after { - clear: both; -} - -.row-fluid .thumbnails { - margin-left: 0; -} - -.thumbnails > li { - float: left; - margin-bottom: 20px; - margin-left: 20px; -} - -.thumbnail { - display: block; - padding: 4px; - line-height: 20px; - border: 1px solid #ddd; - -webkit-border-radius: 4px; - -moz-border-radius: 4px; - border-radius: 4px; - -webkit-box-shadow: 0 1px 3px rgba(0, 0, 0, 0.055); - -moz-box-shadow: 0 1px 3px rgba(0, 0, 0, 0.055); - box-shadow: 0 1px 3px rgba(0, 0, 0, 0.055); - -webkit-transition: all 0.2s ease-in-out; - -moz-transition: all 0.2s ease-in-out; - -o-transition: all 0.2s ease-in-out; - transition: all 0.2s ease-in-out; -} - -a.thumbnail:hover, -a.thumbnail:focus { - border-color: #0088cc; - -webkit-box-shadow: 0 1px 4px rgba(0, 105, 214, 0.25); - -moz-box-shadow: 0 1px 4px rgba(0, 105, 214, 0.25); - box-shadow: 0 1px 4px rgba(0, 105, 214, 0.25); -} - -.thumbnail > img { - display: block; - max-width: 100%; - margin-right: auto; - margin-left: auto; -} - -.thumbnail .caption { - padding: 9px; - color: #555555; -} - -.media, -.media-body { - overflow: hidden; - *overflow: visible; - zoom: 1; -} - -.media, -.media .media { - margin-top: 15px; -} - -.media:first-child { - margin-top: 0; -} - -.media-object { - display: block; -} - -.media-heading { - margin: 0 0 5px; -} - -.media > .pull-left { - margin-right: 10px; -} - -.media > .pull-right { - margin-left: 10px; -} - -.media-list { - margin-left: 0; - list-style: none; -} - -.label, -.badge { - display: inline-block; - padding: 2px 4px; - font-size: 11.844px; - font-weight: bold; - line-height: 14px; - color: #ffffff; - text-shadow: 0 -1px 0 rgba(0, 0, 0, 0.25); - white-space: nowrap; - vertical-align: baseline; - background-color: #999999; -} - -.label { - -webkit-border-radius: 3px; - -moz-border-radius: 3px; - border-radius: 3px; -} - -.badge { - padding-right: 9px; - padding-left: 9px; - -webkit-border-radius: 9px; - -moz-border-radius: 9px; - border-radius: 9px; -} - -.label:empty, -.badge:empty { - display: none; -} - -a.label:hover, -a.label:focus, -a.badge:hover, -a.badge:focus { - color: #ffffff; - text-decoration: none; - cursor: pointer; -} - -.label-important, -.badge-important { - background-color: #b94a48; -} - -.label-important[href], -.badge-important[href] { - background-color: #953b39; -} - -.label-warning, -.badge-warning { - background-color: #f89406; -} - -.label-warning[href], -.badge-warning[href] { - background-color: #c67605; -} - -.label-success, -.badge-success { - background-color: #468847; -} - -.label-success[href], -.badge-success[href] { - background-color: #356635; -} - -.label-info, -.badge-info { - background-color: #3a87ad; -} - -.label-info[href], -.badge-info[href] { - background-color: #2d6987; -} - -.label-inverse, -.badge-inverse { - background-color: #333333; -} - -.label-inverse[href], -.badge-inverse[href] { - background-color: #1a1a1a; -} - -.btn .label, -.btn .badge { - position: relative; - top: -1px; -} - -.btn-mini .label, -.btn-mini .badge { - top: 0; -} - -@-webkit-keyframes progress-bar-stripes { - from { - background-position: 40px 0; - } - to { - background-position: 0 0; - } -} - -@-moz-keyframes progress-bar-stripes { - from { - background-position: 40px 0; - } - to { - background-position: 0 0; - } -} - -@-ms-keyframes progress-bar-stripes { - from { - background-position: 40px 0; - } - to { - background-position: 0 0; - } -} - -@-o-keyframes progress-bar-stripes { - from { - background-position: 0 0; - } - to { - background-position: 40px 0; - } -} - -@keyframes progress-bar-stripes { - from { - background-position: 40px 0; - } - to { - background-position: 0 0; - } -} - -.progress { - height: 20px; - margin-bottom: 20px; - overflow: hidden; - background-color: #f7f7f7; - background-image: -moz-linear-gradient(top, #f5f5f5, #f9f9f9); - background-image: -webkit-gradient(linear, 0 0, 0 100%, from(#f5f5f5), to(#f9f9f9)); - background-image: -webkit-linear-gradient(top, #f5f5f5, #f9f9f9); - background-image: -o-linear-gradient(top, #f5f5f5, #f9f9f9); - background-image: linear-gradient(to bottom, #f5f5f5, #f9f9f9); - background-repeat: repeat-x; - -webkit-border-radius: 4px; - -moz-border-radius: 4px; - border-radius: 4px; - filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#fff5f5f5', endColorstr='#fff9f9f9', GradientType=0); - -webkit-box-shadow: inset 0 1px 2px rgba(0, 0, 0, 0.1); - -moz-box-shadow: inset 0 1px 2px rgba(0, 0, 0, 0.1); - box-shadow: inset 0 1px 2px rgba(0, 0, 0, 0.1); -} - -.progress .bar { - float: left; - width: 0; - height: 100%; - font-size: 12px; - color: #ffffff; - text-align: center; - text-shadow: 0 -1px 0 rgba(0, 0, 0, 0.25); - background-color: #0e90d2; - background-image: -moz-linear-gradient(top, #149bdf, #0480be); - background-image: -webkit-gradient(linear, 0 0, 0 100%, from(#149bdf), to(#0480be)); - background-image: -webkit-linear-gradient(top, #149bdf, #0480be); - background-image: -o-linear-gradient(top, #149bdf, #0480be); - background-image: linear-gradient(to bottom, #149bdf, #0480be); - background-repeat: repeat-x; - filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#ff149bdf', endColorstr='#ff0480be', GradientType=0); - -webkit-box-shadow: inset 0 -1px 0 rgba(0, 0, 0, 0.15); - -moz-box-shadow: inset 0 -1px 0 rgba(0, 0, 0, 0.15); - box-shadow: inset 0 -1px 0 rgba(0, 0, 0, 0.15); - -webkit-box-sizing: border-box; - -moz-box-sizing: border-box; - box-sizing: border-box; - -webkit-transition: width 0.6s ease; - -moz-transition: width 0.6s ease; - -o-transition: width 0.6s ease; - transition: width 0.6s ease; -} - -.progress .bar + .bar { - -webkit-box-shadow: inset 1px 0 0 rgba(0, 0, 0, 0.15), inset 0 -1px 0 rgba(0, 0, 0, 0.15); - -moz-box-shadow: inset 1px 0 0 rgba(0, 0, 0, 0.15), inset 0 -1px 0 rgba(0, 0, 0, 0.15); - box-shadow: inset 1px 0 0 rgba(0, 0, 0, 0.15), inset 0 -1px 0 rgba(0, 0, 0, 0.15); -} - -.progress-striped .bar { - background-color: #149bdf; - background-image: -webkit-gradient(linear, 0 100%, 100% 0, color-stop(0.25, rgba(255, 255, 255, 0.15)), color-stop(0.25, transparent), color-stop(0.5, transparent), color-stop(0.5, rgba(255, 255, 255, 0.15)), color-stop(0.75, rgba(255, 255, 255, 0.15)), color-stop(0.75, transparent), to(transparent)); - background-image: -webkit-linear-gradient(45deg, rgba(255, 255, 255, 0.15) 25%, transparent 25%, transparent 50%, rgba(255, 255, 255, 0.15) 50%, rgba(255, 255, 255, 0.15) 75%, transparent 75%, transparent); - background-image: -moz-linear-gradient(45deg, rgba(255, 255, 255, 0.15) 25%, transparent 25%, transparent 50%, rgba(255, 255, 255, 0.15) 50%, rgba(255, 255, 255, 0.15) 75%, transparent 75%, transparent); - background-image: -o-linear-gradient(45deg, rgba(255, 255, 255, 0.15) 25%, transparent 25%, transparent 50%, rgba(255, 255, 255, 0.15) 50%, rgba(255, 255, 255, 0.15) 75%, transparent 75%, transparent); - background-image: linear-gradient(45deg, rgba(255, 255, 255, 0.15) 25%, transparent 25%, transparent 50%, rgba(255, 255, 255, 0.15) 50%, rgba(255, 255, 255, 0.15) 75%, transparent 75%, transparent); - -webkit-background-size: 40px 40px; - -moz-background-size: 40px 40px; - -o-background-size: 40px 40px; - background-size: 40px 40px; -} - -.progress.active .bar { - -webkit-animation: progress-bar-stripes 2s linear infinite; - -moz-animation: progress-bar-stripes 2s linear infinite; - -ms-animation: progress-bar-stripes 2s linear infinite; - -o-animation: progress-bar-stripes 2s linear infinite; - animation: progress-bar-stripes 2s linear infinite; -} - -.progress-danger .bar, -.progress .bar-danger { - background-color: #dd514c; - background-image: -moz-linear-gradient(top, #ee5f5b, #c43c35); - background-image: -webkit-gradient(linear, 0 0, 0 100%, from(#ee5f5b), to(#c43c35)); - background-image: -webkit-linear-gradient(top, #ee5f5b, #c43c35); - background-image: -o-linear-gradient(top, #ee5f5b, #c43c35); - background-image: linear-gradient(to bottom, #ee5f5b, #c43c35); - background-repeat: repeat-x; - filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#ffee5f5b', endColorstr='#ffc43c35', GradientType=0); -} - -.progress-danger.progress-striped .bar, -.progress-striped .bar-danger { - background-color: #ee5f5b; - background-image: -webkit-gradient(linear, 0 100%, 100% 0, color-stop(0.25, rgba(255, 255, 255, 0.15)), color-stop(0.25, transparent), color-stop(0.5, transparent), color-stop(0.5, rgba(255, 255, 255, 0.15)), color-stop(0.75, rgba(255, 255, 255, 0.15)), color-stop(0.75, transparent), to(transparent)); - background-image: -webkit-linear-gradient(45deg, rgba(255, 255, 255, 0.15) 25%, transparent 25%, transparent 50%, rgba(255, 255, 255, 0.15) 50%, rgba(255, 255, 255, 0.15) 75%, transparent 75%, transparent); - background-image: -moz-linear-gradient(45deg, rgba(255, 255, 255, 0.15) 25%, transparent 25%, transparent 50%, rgba(255, 255, 255, 0.15) 50%, rgba(255, 255, 255, 0.15) 75%, transparent 75%, transparent); - background-image: -o-linear-gradient(45deg, rgba(255, 255, 255, 0.15) 25%, transparent 25%, transparent 50%, rgba(255, 255, 255, 0.15) 50%, rgba(255, 255, 255, 0.15) 75%, transparent 75%, transparent); - background-image: linear-gradient(45deg, rgba(255, 255, 255, 0.15) 25%, transparent 25%, transparent 50%, rgba(255, 255, 255, 0.15) 50%, rgba(255, 255, 255, 0.15) 75%, transparent 75%, transparent); -} - -.progress-success .bar, -.progress .bar-success { - background-color: #5eb95e; - background-image: -moz-linear-gradient(top, #62c462, #57a957); - background-image: -webkit-gradient(linear, 0 0, 0 100%, from(#62c462), to(#57a957)); - background-image: -webkit-linear-gradient(top, #62c462, #57a957); - background-image: -o-linear-gradient(top, #62c462, #57a957); - background-image: linear-gradient(to bottom, #62c462, #57a957); - background-repeat: repeat-x; - filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#ff62c462', endColorstr='#ff57a957', GradientType=0); -} - -.progress-success.progress-striped .bar, -.progress-striped .bar-success { - background-color: #62c462; - background-image: -webkit-gradient(linear, 0 100%, 100% 0, color-stop(0.25, rgba(255, 255, 255, 0.15)), color-stop(0.25, transparent), color-stop(0.5, transparent), color-stop(0.5, rgba(255, 255, 255, 0.15)), color-stop(0.75, rgba(255, 255, 255, 0.15)), color-stop(0.75, transparent), to(transparent)); - background-image: -webkit-linear-gradient(45deg, rgba(255, 255, 255, 0.15) 25%, transparent 25%, transparent 50%, rgba(255, 255, 255, 0.15) 50%, rgba(255, 255, 255, 0.15) 75%, transparent 75%, transparent); - background-image: -moz-linear-gradient(45deg, rgba(255, 255, 255, 0.15) 25%, transparent 25%, transparent 50%, rgba(255, 255, 255, 0.15) 50%, rgba(255, 255, 255, 0.15) 75%, transparent 75%, transparent); - background-image: -o-linear-gradient(45deg, rgba(255, 255, 255, 0.15) 25%, transparent 25%, transparent 50%, rgba(255, 255, 255, 0.15) 50%, rgba(255, 255, 255, 0.15) 75%, transparent 75%, transparent); - background-image: linear-gradient(45deg, rgba(255, 255, 255, 0.15) 25%, transparent 25%, transparent 50%, rgba(255, 255, 255, 0.15) 50%, rgba(255, 255, 255, 0.15) 75%, transparent 75%, transparent); -} - -.progress-info .bar, -.progress .bar-info { - background-color: #4bb1cf; - background-image: -moz-linear-gradient(top, #5bc0de, #339bb9); - background-image: -webkit-gradient(linear, 0 0, 0 100%, from(#5bc0de), to(#339bb9)); - background-image: -webkit-linear-gradient(top, #5bc0de, #339bb9); - background-image: -o-linear-gradient(top, #5bc0de, #339bb9); - background-image: linear-gradient(to bottom, #5bc0de, #339bb9); - background-repeat: repeat-x; - filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#ff5bc0de', endColorstr='#ff339bb9', GradientType=0); -} - -.progress-info.progress-striped .bar, -.progress-striped .bar-info { - background-color: #5bc0de; - background-image: -webkit-gradient(linear, 0 100%, 100% 0, color-stop(0.25, rgba(255, 255, 255, 0.15)), color-stop(0.25, transparent), color-stop(0.5, transparent), color-stop(0.5, rgba(255, 255, 255, 0.15)), color-stop(0.75, rgba(255, 255, 255, 0.15)), color-stop(0.75, transparent), to(transparent)); - background-image: -webkit-linear-gradient(45deg, rgba(255, 255, 255, 0.15) 25%, transparent 25%, transparent 50%, rgba(255, 255, 255, 0.15) 50%, rgba(255, 255, 255, 0.15) 75%, transparent 75%, transparent); - background-image: -moz-linear-gradient(45deg, rgba(255, 255, 255, 0.15) 25%, transparent 25%, transparent 50%, rgba(255, 255, 255, 0.15) 50%, rgba(255, 255, 255, 0.15) 75%, transparent 75%, transparent); - background-image: -o-linear-gradient(45deg, rgba(255, 255, 255, 0.15) 25%, transparent 25%, transparent 50%, rgba(255, 255, 255, 0.15) 50%, rgba(255, 255, 255, 0.15) 75%, transparent 75%, transparent); - background-image: linear-gradient(45deg, rgba(255, 255, 255, 0.15) 25%, transparent 25%, transparent 50%, rgba(255, 255, 255, 0.15) 50%, rgba(255, 255, 255, 0.15) 75%, transparent 75%, transparent); -} - -.progress-warning .bar, -.progress .bar-warning { - background-color: #faa732; - background-image: -moz-linear-gradient(top, #fbb450, #f89406); - background-image: -webkit-gradient(linear, 0 0, 0 100%, from(#fbb450), to(#f89406)); - background-image: -webkit-linear-gradient(top, #fbb450, #f89406); - background-image: -o-linear-gradient(top, #fbb450, #f89406); - background-image: linear-gradient(to bottom, #fbb450, #f89406); - background-repeat: repeat-x; - filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#fffbb450', endColorstr='#fff89406', GradientType=0); -} - -.progress-warning.progress-striped .bar, -.progress-striped .bar-warning { - background-color: #fbb450; - background-image: -webkit-gradient(linear, 0 100%, 100% 0, color-stop(0.25, rgba(255, 255, 255, 0.15)), color-stop(0.25, transparent), color-stop(0.5, transparent), color-stop(0.5, rgba(255, 255, 255, 0.15)), color-stop(0.75, rgba(255, 255, 255, 0.15)), color-stop(0.75, transparent), to(transparent)); - background-image: -webkit-linear-gradient(45deg, rgba(255, 255, 255, 0.15) 25%, transparent 25%, transparent 50%, rgba(255, 255, 255, 0.15) 50%, rgba(255, 255, 255, 0.15) 75%, transparent 75%, transparent); - background-image: -moz-linear-gradient(45deg, rgba(255, 255, 255, 0.15) 25%, transparent 25%, transparent 50%, rgba(255, 255, 255, 0.15) 50%, rgba(255, 255, 255, 0.15) 75%, transparent 75%, transparent); - background-image: -o-linear-gradient(45deg, rgba(255, 255, 255, 0.15) 25%, transparent 25%, transparent 50%, rgba(255, 255, 255, 0.15) 50%, rgba(255, 255, 255, 0.15) 75%, transparent 75%, transparent); - background-image: linear-gradient(45deg, rgba(255, 255, 255, 0.15) 25%, transparent 25%, transparent 50%, rgba(255, 255, 255, 0.15) 50%, rgba(255, 255, 255, 0.15) 75%, transparent 75%, transparent); -} - -.accordion { - margin-bottom: 20px; -} - -.accordion-group { - margin-bottom: 2px; - border: 1px solid #e5e5e5; - -webkit-border-radius: 4px; - -moz-border-radius: 4px; - border-radius: 4px; -} - -.accordion-heading { - border-bottom: 0; -} - -.accordion-heading .accordion-toggle { - display: block; - padding: 8px 15px; -} - -.accordion-toggle { - cursor: pointer; -} - -.accordion-inner { - padding: 9px 15px; - border-top: 1px solid #e5e5e5; -} - -.carousel { - position: relative; - margin-bottom: 20px; - line-height: 1; -} - -.carousel-inner { - position: relative; - width: 100%; - overflow: hidden; -} - -.carousel-inner > .item { - position: relative; - display: none; - -webkit-transition: 0.6s ease-in-out left; - -moz-transition: 0.6s ease-in-out left; - -o-transition: 0.6s ease-in-out left; - transition: 0.6s ease-in-out left; -} - -.carousel-inner > .item > img, -.carousel-inner > .item > a > img { - display: block; - line-height: 1; -} - -.carousel-inner > .active, -.carousel-inner > .next, -.carousel-inner > .prev { - display: block; -} - -.carousel-inner > .active { - left: 0; -} - -.carousel-inner > .next, -.carousel-inner > .prev { - position: absolute; - top: 0; - width: 100%; -} - -.carousel-inner > .next { - left: 100%; -} - -.carousel-inner > .prev { - left: -100%; -} - -.carousel-inner > .next.left, -.carousel-inner > .prev.right { - left: 0; -} - -.carousel-inner > .active.left { - left: -100%; -} - -.carousel-inner > .active.right { - left: 100%; -} - -.carousel-control { - position: absolute; - top: 40%; - left: 15px; - width: 40px; - height: 40px; - margin-top: -20px; - font-size: 60px; - font-weight: 100; - line-height: 30px; - color: #ffffff; - text-align: center; - background: #222222; - border: 3px solid #ffffff; - -webkit-border-radius: 23px; - -moz-border-radius: 23px; - border-radius: 23px; - opacity: 0.5; - filter: alpha(opacity=50); -} - -.carousel-control.right { - right: 15px; - left: auto; -} - -.carousel-control:hover, -.carousel-control:focus { - color: #ffffff; - text-decoration: none; - opacity: 0.9; - filter: alpha(opacity=90); -} - -.carousel-indicators { - position: absolute; - top: 15px; - right: 15px; - z-index: 5; - margin: 0; - list-style: none; -} - -.carousel-indicators li { - display: block; - float: left; - width: 10px; - height: 10px; - margin-left: 5px; - text-indent: -999px; - background-color: #ccc; - background-color: rgba(255, 255, 255, 0.25); - border-radius: 5px; -} - -.carousel-indicators .active { - background-color: #fff; -} - -.carousel-caption { - position: absolute; - right: 0; - bottom: 0; - left: 0; - padding: 15px; - background: #333333; - background: rgba(0, 0, 0, 0.75); -} - -.carousel-caption h4, -.carousel-caption p { - line-height: 20px; - color: #ffffff; -} - -.carousel-caption h4 { - margin: 0 0 5px; -} - -.carousel-caption p { - margin-bottom: 0; -} - -.hero-unit { - padding: 60px; - margin-bottom: 30px; - font-size: 18px; - font-weight: 200; - line-height: 30px; - color: inherit; - background-color: #eeeeee; - -webkit-border-radius: 6px; - -moz-border-radius: 6px; - border-radius: 6px; -} - -.hero-unit h1 { - margin-bottom: 0; - font-size: 60px; - line-height: 1; - letter-spacing: -1px; - color: inherit; -} - -.hero-unit li { - line-height: 30px; -} - -.pull-right { - float: right; -} - -.pull-left { - float: left; -} - -.hide { - display: none; -} - -.show { - display: block; -} - -.invisible { - visibility: hidden; -} - -.affix { - position: fixed; -} diff --git a/wp-content/plugins/wp-security-scan/res/css/bootstrap.overrides.css b/wp-content/plugins/wp-security-scan/res/css/bootstrap.overrides.css deleted file mode 100644 index 71cd2952..00000000 --- a/wp-content/plugins/wp-security-scan/res/css/bootstrap.overrides.css +++ /dev/null @@ -1,19 +0,0 @@ -.action-collapse-icon-12p { - background: url("../images/minus.gif") no-repeat scroll left bottom transparent; - display: inline-block; - height: 16px; - width: 16px; -} -.action-expand-icon-12p { - background: url("../images/plus.gif") no-repeat scroll left bottom transparent; - display: inline-block; - height: 16px; - width: 16px; -} - -.wsdplugin_content h3 { font-size: 17.5px; } -.wsdplugin_content h1, -.wsdplugin_content h2, -.wsdplugin_content h3 { line-height: 22px; } - -ul, ol { margin-left: 0; } diff --git a/wp-content/plugins/wp-security-scan/res/css/index.php b/wp-content/plugins/wp-security-scan/res/css/index.php deleted file mode 100644 index fe0ab8ea..00000000 --- a/wp-content/plugins/wp-security-scan/res/css/index.php +++ /dev/null @@ -1 +0,0 @@ -get_var("SELECT `ID` FROM $wpdb->users WHERE user_login='admin';"); - if(empty($u)){ - self::alert($actionName, $alertType, WpsSettings::ALERT_INFO, - sprintf(__('User "%s" (with administrative rights) was not found',WpsSettings::TEXT_DOMAIN), 'admin'), - sprintf(__('

One well known and dangerous WordPress security vulnerability is User Enumeration, in which a - malicious user is able to enumerate a valid WordPress user account to launch a brute force attack against it. - In order to help deter this type of attack, it is important not to have the default WordPress administrator - username enabled on your blog.

',WpsSettings::TEXT_DOMAIN), 'http://www.acunetix.com/blog/web-security-zone/articles/default-wordpress-administrator-account/', '_blank') - ); - } - else { - // check to see if this user is an administrator - $userRole = $wpdb->get_var("SELECT meta_value FROM ".$wpdb->usermeta. " WHERE user_id = $u AND meta_key = '".$wpdb->prefix."user_level'"); - if(! empty($userRole)){ - $userRole = intval($userRole); - if(in_array($userRole, array(8,9,10))){ - self::alert($actionName, $alertType, WpsSettings::ALERT_CRITICAL, - sprintf(__('The default user "%s" was found',WpsSettings::TEXT_DOMAIN), 'admin'), - sprintf(__('

One well known and dangerous WordPress security vulnerability is User Enumeration, in which a malicious user is able to enumerate - a valid WordPress user account to launch a brute force attack against it.

-

In order to help deter this type of attack, you should change your default WordPress administrator - username to something more difficult to guess.

',WpsSettings::TEXT_DOMAIN), 'http://www.acunetix.com/blog/web-security-zone/articles/default-wordpress-administrator-account/', '_blank'), - // solution - __('

Do not make the following change unless you are comfortable working with PHPMyAdmin and MySQL. If not, ask someone who is familiar with WordPress and MySQL to assist you.

-

Also, it is of utmost importance to backup your whole blog - including the database - before making any of the changes described below.

-

To change your WordPress default admin username, navigate to your web host\'s MySQL administration tool (probably PHPMyAdmin) and browse to your WordPress database. - Locate the users table, in which you will find a user_login column. One of the rows will contain admin in the field. - Change this to a complex and hard-to-guess name, which ideally consists of alpha-numeric characters.

-

IMPORTANT: Even if the username is hard to guess, you will still need a very strong password.

',WpsSettings::TEXT_DOMAIN)); - return; - } - } - } - } - - // type: overwrite - public static function check_tablePrefix() - { - global $wpdb, $wpsPluginAlertsArray; - $actionName = $wpsPluginAlertsArray['check_table_prefix']['name']; - $alertType = $wpsPluginAlertsArray['check_table_prefix']['type']; - - if(strcasecmp('wp_', $wpdb->prefix)==0){ - self::alert($actionName, $alertType, WpsSettings::ALERT_CRITICAL, - sprintf(__('The default WordPress database prefix (%s) is used',WpsSettings::TEXT_DOMAIN), $wpdb->prefix), - __('

The majority of reported WordPress database security attacks were performed by exploiting SQL Injection vulnerabilities. - By renaming the WordPress database table prefixes you are securing your WordPress blog and website from zero day SQL injections attacks.

-

Therefore by renaming the WordPress database table prefixes, you are automatically enforcing your WordPress database security against such dangerous attacks - because the attacker would not be able to guess the table names.

-

We recommend to use difficult to guess prefixes, like long random strings which include both letters and numbers.

',WpsSettings::TEXT_DOMAIN), - sprintf(__('

This plugin can automatically do this for you, but if you want to do it manually then please read this article first.

',WpsSettings::TEXT_DOMAIN), - 'admin.php?page=wps_database', - 'http://www.websitedefender.com/wordpress-security/change-wordpress-database-prefix/', '_blank') - ); - } - else { - self::alert($actionName, $alertType, WpsSettings::ALERT_INFO, - __('The default WordPress database prefix is not used',WpsSettings::TEXT_DOMAIN), - __('

The majority of reported WordPress database security attacks were performed by exploiting SQL Injection vulnerabilities. - By renaming the WordPress database table prefixes you are securing your WordPress blog and website from zero day SQL injections attacks.

-

Therefore by renaming the WordPress database table prefixes, you are automatically enforcing your WordPress database security against such dangerous attacks because the attacker would not be able to guess the table names.

',WpsSettings::TEXT_DOMAIN) - ); - } - } - - // type: overwrite - public static function check_currentVersion() - { - global $wpsPluginAlertsArray; - $actionName = $wpsPluginAlertsArray['check_wp_current_version']['name']; - $alertType = $wpsPluginAlertsArray['check_wp_current_version']['type']; - - $c = get_site_transient('update_core'); - if(is_object($c)) - { - if(empty($c->updates)) { - self::alert($actionName, $alertType, WpsSettings::ALERT_INFO, - __('You have the latest version of WordPress installed',WpsSettings::TEXT_DOMAIN), - __('

The latest WordPress version is usually more stable and secure, and is only released to include new features or fix technical and WordPress security bugs; - making it an important part of your website administration to keep up to date since some fixes might resolve security issues.

-

Running an older WordPress version could put your blog security at risk, allowing a hacker to exploit known vulnerabilities for your specific version and take full control over your web server.

',WpsSettings::TEXT_DOMAIN) - ); - } - else { - if (!empty($c->updates[0])) - { - $c = $c->updates[0]; - if (!isset($c->response) || 'latest' == $c->response ) { - self::alert($actionName, $alertType, WpsSettings::ALERT_INFO, - __('You have the latest version of WordPress installed',WpsSettings::TEXT_DOMAIN), - __('

The latest WordPress version is usually more stable and secure, and is only released to include new features or fix technical and WordPress security bugs; - making it an important part of your website administration to keep up to date since some fixes might resolve security issues.

-

Running an older WordPress version could put your blog security at risk, allowing a hacker to exploit known vulnerabilities for your specific version and take full control over your web server.

',WpsSettings::TEXT_DOMAIN) - ); - } - elseif ('upgrade' == $c->response) { - self::alert($actionName, $alertType, WpsSettings::ALERT_CRITICAL, - sprintf(__('An updated version of WordPress is available: %s',WpsSettings::TEXT_DOMAIN), $c->current), - __('

The latest WordPress version is usually more stable and secure, and is only released to include new features or fix technical and WordPress security bugs; - making it an important part of your website administration to keep up to date since some fixes might resolve security issues.

-

Running an older WordPress version could put your blog security at risk, allowing a hacker to exploit known vulnerabilities for your specific version and take full control over your web server.

',WpsSettings::TEXT_DOMAIN), - sprintf(__('

It is recommended to update your WordPress installation as soon as possible. More information on updating WordPress manually and automatically - can be found on the official WordPress site.

',WpsSettings::TEXT_DOMAIN), 'http://codex.wordpress.org/Updating_WordPress', '_blank') - ); - } - } - } - } - } - - // type: overwrite - public static function check_files() - { - global $wpsPluginAlertsArray; - - $actionName = $wpsPluginAlertsArray['check_index_wp_content']['name']; - $alertType = $wpsPluginAlertsArray['check_index_wp_content']['type']; - $path = WP_CONTENT_DIR.'/index.php'; - if(!is_file($path)) { - self::alert($actionName, $alertType, WpsSettings::ALERT_MEDIUM, - sprintf(__('The "%s" file was not found in the "%s" directory',WpsSettings::TEXT_DOMAIN), 'index.php', '/wp-content'), - __('

A directory listing provides an attacker with the complete index of all the resources located inside of the directory. The specific risks and consequences vary depending on which files are listed and accessible.

-

Therefore, it is important to protect your directories by having an empty index.php or index.htm file inside them.

',WpsSettings::TEXT_DOMAIN), - sprintf(__('

This plugin can automatically create an empty "%s" file in the following directories: wp-content, wp-content/plugins, wp-content/themes and wp-content/uploads if - the option "%s" is checked on the plugin\'s settings page.

',WpsSettings::TEXT_DOMAIN), - 'index.php', 'Try to create the index.php file in the wp-content, wp-content/plugins, wp-content/themes and wp-content/uploads directories to prevent directory listing') - ); - } - else { - self::alert($actionName, $alertType, WpsSettings::ALERT_INFO, - sprintf(__('The "%s" file was found in the "%s" directory',WpsSettings::TEXT_DOMAIN), 'index.php', '/wp-content'), - __('

A directory listing provides an attacker with the complete index of all the resources located inside of the directory. The specific risks and consequences vary depending on which files are listed and accessible.

-

Therefore, it is important to protect your directories by having an empty index.php or index.htm file inside them.

',WpsSettings::TEXT_DOMAIN) - ); - } - - $actionName = $wpsPluginAlertsArray['check_index_wp_plugins']['name']; - $alertType = $wpsPluginAlertsArray['check_index_wp_plugins']['type']; - $path = WP_CONTENT_DIR.'/plugins/index.php'; - if(!is_file($path)) { - self::alert($actionName, $alertType, WpsSettings::ALERT_MEDIUM, - sprintf(__('The "%s" file was not found in the "%s" directory',WpsSettings::TEXT_DOMAIN), 'index.php', '/wp-content/plugins'), - __('

A directory listing provides an attacker with the complete index of all the resources located inside of the directory. The specific risks and consequences vary depending on which files are listed and accessible.

-

Therefore, it is important to protect your directories by having an empty index.php or index.htm file inside them.

',WpsSettings::TEXT_DOMAIN), - sprintf(__('

This plugin can automatically create an empty "%s" file in the following directories: wp-content, wp-content/plugins, wp-content/themes and wp-content/uploads if - the option "%s" is checked on the plugin\'s settings page.

',WpsSettings::TEXT_DOMAIN), - 'index.php', 'Try to create the index.php file in the wp-content, wp-content/plugins, wp-content/themes and wp-content/uploads directories to prevent directory listing') - ); - } - else { - self::alert($actionName, $alertType, WpsSettings::ALERT_INFO, - sprintf(__('The "%s" file was found in the "%s" directory',WpsSettings::TEXT_DOMAIN), 'index.php', '/wp-content/plugins'), - __('

A directory listing provides an attacker with the complete index of all the resources located inside of the directory. The specific risks and consequences vary depending on which files are listed and accessible.

-

Therefore, it is important to protect your directories by having an empty index.php or index.htm file inside them.

',WpsSettings::TEXT_DOMAIN) - ); - } - - $actionName = $wpsPluginAlertsArray['check_index_wp_themes']['name']; - $alertType = $wpsPluginAlertsArray['check_index_wp_themes']['type']; - $path = WP_CONTENT_DIR.'/themes/index.php'; - if(!is_file($path)) { - self::alert($actionName, $alertType, WpsSettings::ALERT_MEDIUM, - sprintf(__('The "%s" file was not found in the "%s" directory',WpsSettings::TEXT_DOMAIN), 'index.php', '/wp-content/themes'), - __('

A directory listing provides an attacker with the complete index of all the resources located inside of the directory. The specific risks and consequences vary depending on which files are listed and accessible.

-

Therefore, it is important to protect your directories by having an empty index.php or index.htm file inside them.

',WpsSettings::TEXT_DOMAIN), - sprintf(__('

This plugin can automatically create an empty "%s" file in the following directories: wp-content, wp-content/plugins, wp-content/themes and wp-content/uploads if - the option "%s" is checked on the plugin\'s settings page.

',WpsSettings::TEXT_DOMAIN), - 'index.php', 'Try to create the index.php file in the wp-content, wp-content/plugins, wp-content/themes and wp-content/uploads directories to prevent directory listing') - ); - } - else { - self::alert($actionName, $alertType, WpsSettings::ALERT_INFO, - sprintf(__('The "%s" file was found in the "%s" directory',WpsSettings::TEXT_DOMAIN), 'index.php', '/wp-content/themes'), - __('

A directory listing provides an attacker with the complete index of all the resources located inside of the directory. The specific risks and consequences vary depending on which files are listed and accessible.

-

Therefore, it is important to protect your directories by having an empty index.php or index.htm file inside them.

',WpsSettings::TEXT_DOMAIN) - ); - } - - $actionName = $wpsPluginAlertsArray['check_index_wp_uploads']['name']; - $alertType = $wpsPluginAlertsArray['check_index_wp_uploads']['type']; - $path = WP_CONTENT_DIR.'/uploads'; - if(is_dir($path)) - { - if(!is_file(WP_CONTENT_DIR.'/uploads/index.php')) { - self::alert($actionName, $alertType, WpsSettings::ALERT_MEDIUM, - sprintf(__('The "%s" file was not found in the "%s" directory',WpsSettings::TEXT_DOMAIN), 'index.php', '/wp-content/uploads'), - __('

A directory listing provides an attacker with the complete index of all the resources located inside of the directory. The specific risks and consequences vary depending on which files are listed and accessible.

-

Therefore, it is important to protect your directories by having an empty index.php or index.htm file inside them.

',WpsSettings::TEXT_DOMAIN), - sprintf(__('

This plugin can automatically create an empty "%s" file in the following directories: wp-content, wp-content/plugins, wp-content/themes and wp-content/uploads if the - option "%s" is checked on the plugin\'s settings page.

',WpsSettings::TEXT_DOMAIN), - 'index.php', 'Try to create the index.php file in the wp-content, wp-content/plugins, wp-content/themes and wp-content/uploads directories to prevent directory listing') - ); - } - else { - self::alert($actionName, $alertType, WpsSettings::ALERT_INFO, - sprintf(__('The "%s" file was found in the "%s" directory',WpsSettings::TEXT_DOMAIN), 'index.php', '/wp-content/uploads'), - __('

A directory listing provides an attacker with the complete index of all the resources located inside of the directory. The specific risks and consequences vary depending on which files are listed and accessible.

-

Therefore, it is important to protect your directories by having an empty index.php or index.htm file inside them.

',WpsSettings::TEXT_DOMAIN) - ); - } - } - - $actionName = $wpsPluginAlertsArray['check_htaccess_wp_admin']['name']; - $alertType = $wpsPluginAlertsArray['check_htaccess_wp_admin']['type']; - $path = ABSPATH.'wp-admin/.htaccess'; - if(!is_file($path)){ - self::alert($actionName, $alertType, WpsSettings::ALERT_MEDIUM, - sprintf(__('The "%s" file was not found in the "%s" directory',WpsSettings::TEXT_DOMAIN), '.htaccess', 'wp-admin'), - __('

An .htaccess file is a configuration file which provides the ability to specify configuration settings for a specific directory in a website. - The .htaccess file can include one or more configuration settings which apply only for the directory in which the .htaccess file has been placed. - So while web servers have their own main configuration settings file, the .htaccess file can be used to override their main configuration settings.

',WpsSettings::TEXT_DOMAIN), - sprintf(__('

Please refer to this article for more information on how to create an .htaccess file.

',WpsSettings::TEXT_DOMAIN), - 'http://www.acunetix.com/blog/web-security-zone/articles/what-is-an-htaccess-file/', '_blank') - ); - } - else { - self::alert($actionName, $alertType, WpsSettings::ALERT_INFO, - sprintf(__('The "%s" file was found in the "%s" directory',WpsSettings::TEXT_DOMAIN), '.htaccess', 'wp-admin'), - __('

An .htaccess file is a configuration file which provides the ability to specify configuration settings for a specific directory in a website. - The .htaccess file can include one or more configuration settings which apply only for the directory in which the .htaccess file has been placed. - So while web servers have their own main configuration settings file, the .htaccess file can be used to override their main configuration settings.

',WpsSettings::TEXT_DOMAIN) - ); - } - - $actionName = $wpsPluginAlertsArray['check_readme_wp_root']['name']; - $alertType = $wpsPluginAlertsArray['check_readme_wp_root']['type']; - $path = ABSPATH.'readme.html'; - if(is_file($path)) - { - if(is_readable($path)){ - $fsize = @filesize($path); - // couldn't retrieve the file's size - if($fsize > 0){ - self::alert($actionName, $alertType, WpsSettings::ALERT_MEDIUM, - __('The readme.html file was found in the root directory',WpsSettings::TEXT_DOMAIN), - __('

A default WordPress installation contains a readme.html file. - This file is a simple html file that does not contain executable content that can be exploited by hackers or malicious users. - Still, this file can provide hackers the version of your WordPress installation, therefore it is important to either delete this file or make it inaccessible for your visitors.

',WpsSettings::TEXT_DOMAIN), - sprintf(__('

This plugin can automatically delete its content if the option "%s" is checked on the plugin\'s settings page. - You can also delete this file manually by connecting to your website through an FTP connection.

',WpsSettings::TEXT_DOMAIN), 'Empty the content of the readme.html file from the root directory.') - ); - } - else { - self::alert($actionName, $alertType, WpsSettings::ALERT_INFO, - __('The readme.html file is either empty or not accessible.',WpsSettings::TEXT_DOMAIN), - __('

A default WordPress installation contains a readme.html file. - This file is a simple html file that does not contain executable content that can be exploited by hackers or malicious users. - Still, this file can provide hackers the version of your WordPress installation, therefore it is important to either delete this file or make it inaccessible for your visitors.

',WpsSettings::TEXT_DOMAIN) - ); - } - } - else { - self::alert($actionName, $alertType, WpsSettings::ALERT_INFO, - __('The readme.html file is not accessible.',WpsSettings::TEXT_DOMAIN), - __('

A default WordPress installation contains a readme.html file. - This file is a simple html file that does not contain executable content that can be exploited by hackers or malicious users. - Still, this file can provide hackers the version of your WordPress installation, therefore it is important to either delete this file or make it inaccessible for your visitors.

',WpsSettings::TEXT_DOMAIN) - ); - } - } - else{ - // file not found or file is not accessible - self::alert($actionName, $alertType, WpsSettings::ALERT_INFO, - __('The readme.html file was not found in the root directory',WpsSettings::TEXT_DOMAIN), - __('

A default WordPress installation contains a readme.html file. - This file is a simple html file that does not contain executable content that can be exploited by hackers or malicious users. - Still, this file can provide hackers the version of your WordPress installation, therefore it is important to either delete this file or make it inaccessible for your visitors.

',WpsSettings::TEXT_DOMAIN) - ); - } - } - - //type: overwrite - //@since v4.0.2 - static function check_adminInstallFile() - { - global $wpsPluginAlertsArray; - - $actionName = $wpsPluginAlertsArray['check_wp_admin_install']['name']; - $alertType = $wpsPluginAlertsArray['check_wp_admin_install']['type']; - $path = ABSPATH.'wp-admin/install.php'; - if(is_file($path)) { - self::alert($actionName, $alertType, WpsSettings::ALERT_MEDIUM, - sprintf(__('The "%s" file was found in the "%s" directory',WpsSettings::TEXT_DOMAIN), 'install.php', '/wp-admin'), - __('

The install.php file is needed to install WordPress and it is good practice to restrict access to it or delete it afterwards.

',WpsSettings::TEXT_DOMAIN), - __('

Change file permissions 000 chmod(000) or delete it from the /wp-admin directory

',WpsSettings::TEXT_DOMAIN) - ); - } - else { - self::alert($actionName, $alertType, WpsSettings::ALERT_INFO, - sprintf(__('The "%s" file was not found in the "%s" directory',WpsSettings::TEXT_DOMAIN), 'install.php', '/wp-admin'), - __('

The install.php file is needed to install WordPress and it is good practice to restrict access to it or delete it afterwards.

',WpsSettings::TEXT_DOMAIN) - ); - } - } - //type: overwrite - //@since v4.0.2 - static function check_adminUpgradeFile() - { - global $wpsPluginAlertsArray; - - $actionName = $wpsPluginAlertsArray['check_wp_admin_upgrade']['name']; - $alertType = $wpsPluginAlertsArray['check_wp_admin_upgrade']['type']; - $path = ABSPATH.'wp-admin/upgrade.php'; - if(is_file($path)) { - self::alert($actionName, $alertType, WpsSettings::ALERT_MEDIUM, - sprintf(__('The "%s" file was found in the "%s" directory',WpsSettings::TEXT_DOMAIN), 'upgrade.php', '/wp-admin'), - __('

The upgrade.php file is needed to upgrade WordPress and it is good practice to restrict access to it or delete it afterwards.

',WpsSettings::TEXT_DOMAIN), - __('

Change file permissions 000 chmod(000) or delete it from the /wp-admin directory

',WpsSettings::TEXT_DOMAIN) - ); - } - else { - self::alert($actionName, $alertType, WpsSettings::ALERT_INFO, - sprintf(__('The "%s" file was found in the "%s" directory',WpsSettings::TEXT_DOMAIN), 'upgrade.php', '/wp-admin'), - __('

The upgrade.php file is needed to upgrade WordPress and it is good practice to restrict access to it or delete it afterwards.

',WpsSettings::TEXT_DOMAIN) - ); - } - } -} \ No newline at end of file diff --git a/wp-content/plugins/wp-security-scan/res/inc/WsdInfo.php b/wp-content/plugins/wp-security-scan/res/inc/WsdInfo.php deleted file mode 100644 index c6be7f55..00000000 --- a/wp-content/plugins/wp-security-scan/res/inc/WsdInfo.php +++ /dev/null @@ -1,306 +0,0 @@ -updates)) - { - return ''.__('You have the latest version of WordPress.',WpsSettings::TEXT_DOMAIN).''; - } - - if (!empty($c->updates[0])) - { - $c = $c->updates[0]; - - if ( !isset($c->response) || 'latest' == $c->response ) { - return ''.__('You have the latest version of WordPress.',WpsSettings::TEXT_DOMAIN).''; - } - - if ('upgrade' == $c->response) - { - $lv = $c->current; - $m = ''.sprintf(__('A new version of WordPress (%s) is available. You should upgrade to the latest version.',WpsSettings::TEXT_DOMAIN), $lv).''; - return __($m); - } - } - } - return ''.__('An error has occurred while trying to retrieve the status of your WordPress version.',WpsSettings::TEXT_DOMAIN).''; - } - - public static function getDatabasePrefixInfo() - { - global $table_prefix; - if (strcasecmp('wp_', $table_prefix)==0) { - return '' - .__('Your database prefix should not be wp_.',WpsSettings::TEXT_DOMAIN) - .'('.__('read more',WpsSettings::TEXT_DOMAIN).')'; - } - return ''.__('Your database prefix is not wp_.',WpsSettings::TEXT_DOMAIN).''; - } - - public static function getWpVersionStatusInfo() - { - if (WsdSecurity::$isVersionHidden) { - return ''.__('The WordPress version is hidden for all users but administrators.',WpsSettings::TEXT_DOMAIN).''; - } - } - - public static function getPhpStartupErrorStatusInfo() - { - $dse = strtolower(ini_get('display_startup_errors')); - if ($dse == 0) { - return ''.__('Startup errors are not displayed.',WpsSettings::TEXT_DOMAIN).'
'; - } - return ''.__('Startup errors are displayed.',WpsSettings::TEXT_DOMAIN).''.'
'; - } - - public static function getAdminUsernameInfo() - { - global $wpdb; - $u = $wpdb->get_var("SELECT `ID` FROM $wpdb->users WHERE user_login='admin';"); - if (empty($u)) { - return ''.__('User admin was not found.',WpsSettings::TEXT_DOMAIN).''; - } - return ''.__('User admin was found! You should change it in order to avoid user enumeration attacks.',WpsSettings::TEXT_DOMAIN).''; - } - - public static function getWpAdminHtaccessInfo() - { - $file = trailingslashit(ABSPATH).'wp-admin/.htaccess'; - if (is_file($file)) { - return ''.__('The .htaccess file was found in the wp-admin directory.',WpsSettings::TEXT_DOMAIN).''; - } - return '' - .__('The .htaccess file was not found in the wp-admin directory.',WpsSettings::TEXT_DOMAIN) - .'('.__('read more',WpsSettings::TEXT_DOMAIN).')'; - } - - public static function getDatabaseUserAccessRightsInfo() - { - $rights = WsdInfoServer::getDatabaseUserAccessRights(); - $rightsNeeded = $rights['rightsNeeded']; - $rightsHaving = $rights['rightsHaving']; - $rightsMissing = array_diff($rightsNeeded, $rightsHaving); - - if ($rights['rightsTooMuch']) { - $e = ''.implode(', ', $rightsNeeded).''; - $m = sprintf(__("The user currently configured to access the WordPress Database holds too many rights. - We suggest that you limit his rights (to only %s) or to use another User with more limited rights instead, to increase your website's Security.",WpsSettings::TEXT_DOMAIN),$e); - return ''.$m.''; - } - else - { - if($rights['rightsEnough']){ - $m = __("The user currently configured to access the WordPress Database holds the appropriate rights to interact with the database.",WpsSettings::TEXT_DOMAIN); - return ''.$m.''; - } - else { - $missing = ''.implode(', ', $rightsMissing).''; - $m = sprintf(__("The user currently configured to access the WordPress Database is missing the following rights to interact with the database: %s",WpsSettings::TEXT_DOMAIN),$missing); - return ''.$m.''; - } - } - } - - public static function getWpContentIndexInfo() - { - if (is_file(trailingslashit(WP_CONTENT_DIR).'index.php')) { - return ''.__('The index.php file was found in the wp-content directory.',WpsSettings::TEXT_DOMAIN).''.'
'; - } - return ''.__('The index.php file was not found in the wp-content directory! You should create one in order to prevent directory listings.',WpsSettings::TEXT_DOMAIN).''.'
'; - } - - public static function getWpContentPluginsIndexInfo() - { - $dirPath = trailingslashit(WP_CONTENT_DIR).'plugins/'; - if(!is_dir($dirPath)) { return ''; } - if (is_file($dirPath.'index.php')) { - return ''.__('The index.php file was found in the plugins directory.',WpsSettings::TEXT_DOMAIN).''.'
'; - } - return ''.__('The index.php file was not found in the plugins directory! You should create one in order to prevent directory listings.',WpsSettings::TEXT_DOMAIN).''.'
'; - } - - public static function getWpContentThemesIndexInfo() - { - $dirPath = trailingslashit(WP_CONTENT_DIR).'themes/'; - if(!is_dir($dirPath)) { return ''; } - if (is_file($dirPath.'index.php')) { - return ''.__('The index.php file was found in the themes directory.',WpsSettings::TEXT_DOMAIN).''.'
'; - } - return ''.__('The index.php file was not found in the themes directory! You should create one in order to prevent directory listings.',WpsSettings::TEXT_DOMAIN).''.'
'; - } - - public static function getWpContentUploadsIndexInfo() - { - $dirPath = trailingslashit(WP_CONTENT_DIR).'uploads/'; - if(!is_dir($dirPath)) { return ''; } - if (is_file($dirPath.'index.php')) { - return ''.__('The index.php file was found in the uploads directory.',WpsSettings::TEXT_DOMAIN).''.'
'; - } - return ''.__('The index.php file was not found in the uploads directory! You should create one in order to prevent directory listings.',WpsSettings::TEXT_DOMAIN).''.'
'; - } - -} - -class WsdInfoServer extends WsdInfo -{ - public static function getServerInfo() - { - global $wpdb; - $sqlversion = $wpdb->get_var("SELECT VERSION() AS version"); - $mysqlinfo = $wpdb->get_results("SHOW VARIABLES LIKE 'sql_mode'"); - if (is_array($mysqlinfo)) $sql_mode = $mysqlinfo[0]->Value; - if (empty($sql_mode)) $sql_mode = __('Not set',WpsSettings::TEXT_DOMAIN); - $sm = ini_get('safe_mode'); - if (strcasecmp('On', $sm) == 0) { $safe_mode = __('On',WpsSettings::TEXT_DOMAIN); } - else { $safe_mode = __('Off',WpsSettings::TEXT_DOMAIN); } - if(ini_get('allow_url_fopen')) $allow_url_fopen = __('On',WpsSettings::TEXT_DOMAIN); - else $allow_url_fopen = __('Off',WpsSettings::TEXT_DOMAIN); - if(ini_get('upload_max_filesize')) $upload_max = ini_get('upload_max_filesize'); - else $upload_max = __('N/A',WpsSettings::TEXT_DOMAIN); - if(ini_get('post_max_size')) $post_max = ini_get('post_max_size'); - else $post_max = __('N/A',WpsSettings::TEXT_DOMAIN); - if(ini_get('max_execution_time')) $max_execute = ini_get('max_execution_time'); - else $max_execute = __('N/A',WpsSettings::TEXT_DOMAIN); - if(ini_get('memory_limit')) $memory_limit = ini_get('memory_limit'); - else $memory_limit = __('N/A',WpsSettings::TEXT_DOMAIN); - if (function_exists('memory_get_usage')) $memory_usage = round(memory_get_usage() / 1024 / 1024, 2) . __(' MByte',WpsSettings::TEXT_DOMAIN); - else $memory_usage = __('N/A',WpsSettings::TEXT_DOMAIN); - if (is_callable('exif_read_data')) $exif = __('Yes',WpsSettings::TEXT_DOMAIN). " ( V" . substr(phpversion('exif'),0,4) . ")" ; - else $exif = __('No',WpsSettings::TEXT_DOMAIN); - if (is_callable('iptcparse')) $iptc = __('Yes',WpsSettings::TEXT_DOMAIN); - else $iptc = __('No',WpsSettings::TEXT_DOMAIN); - if (is_callable('xml_parser_create')) $xml = __('Yes',WpsSettings::TEXT_DOMAIN); - else $xml = __('No',WpsSettings::TEXT_DOMAIN); - - $sqlModeText = __('SQL Mode (sql_mode) is a MySQL system variable. By means of this variable the MySQL Server SQL Mode is controlled. - Many operational characteristics of MySQL Server can be configured by setting the SQL Mode. - By setting the SQL Mode appropriately, a client program can instruct the server how strict or forgiving to be about accepting input data, enable or disable behaviors relating to standard SQL conformance, - or provide better compatibility with other database systems. By default, the server uses a sql_mode value of \'\' (the empty string), which enables no restrictions. - Thus, the server operates in forgiving mode (non-strict mode) by default. In non-strict mode, the MySQL server converts erroneous input values to the closest legal - values (as determined from column definitions) and continues on its way.',WpsSettings::TEXT_DOMAIN); - $phpSafeModeText = __('The PHP Safe Mode (safe_mode) is an attempt to solve the shared-server security problem. - It is architecturally incorrect to try to solve this problem at the PHP level, but since the alternatives at the web server and OS levels aren\'t - very realistic, many people, especially ISP\'s, use safe mode for now.',WpsSettings::TEXT_DOMAIN); - $phpAllowFopenText = __('PHP allow_url_fopen option, if enabled (allows PHP\'s file functions - such as \'file_get_contents()\' and the \'include\' and \'require\' statements), - can retrieve data from remote locations, like an FTP or web site, which may pose a security risk.',WpsSettings::TEXT_DOMAIN); - $phpMemoryLimitText = __('PHP memory_limit option sets the maximum amount of memory in bytes that a script is allowed to allocate. - By enabling a realistic memory_limit you can protect your applications from certain types of Denial of Service attacks, and also from bugs in - applications (such as infinite loops, poor use of image based functions, or other memory intensive mistakes).',WpsSettings::TEXT_DOMAIN); - $phpMaxUploadSizeText = __('PHP upload_max_filesize option limits the maximum size of files that PHP will accept through uploads. Attackers may attempt to send grossly oversized files to exhaust your system resources; - by setting a realistic value here you can mitigate some of the damage by those attacks.',WpsSettings::TEXT_DOMAIN); - $phpMaxPostSizeText = __('PHP post_max_size option limits the maximum size of the POST request that PHP will process. Attackers may attempt to send grossly oversized POST requests to exhaust your system resources; - by setting a realistic value here you can mitigate some of the damage by those attacks.',WpsSettings::TEXT_DOMAIN); - $phpScriptExecTimeText = __('PHP max_execution_time option sets the maximum time in seconds a script is allowed to run before it is terminated by the parser. - This helps prevent poorly written scripts from tying up the server.',WpsSettings::TEXT_DOMAIN); - $exifText = __('PHP exif extension enables you to work with image meta data. For example, you may use exif functions to read meta data of pictures taken from digital cameras by working with - information stored in the headers of the JPEG and TIFF images.',WpsSettings::TEXT_DOMAIN); - $iptcText = __('IPTC data is a method of storing textual information in images defined by the International Press Telecommunications Council. - It was developed for press photographers who need to attach information to images when they are submitting them electronically but it is useful for all photographers. - It provides a standard way of storing information such as captions, keywords, location. Because the information is stored in the image in a standard way this information - can be accessed by other IPTC aware applications.',WpsSettings::TEXT_DOMAIN); - $xmlText = __('XML (eXtensible Markup Language) is a data format for structured document interchange on the Web. It is a standard defined by the World Wide Web Consortium (W3C).',WpsSettings::TEXT_DOMAIN); - - $str = ''; - $str .= ''; - - $str .= '

'; - - $str .= ''; - return $str; - } - - /** - * @public - * @static - * @global $wpdb, DB_USER, DB_HOST - * - * Retrieve the rights the current used user to connect to the database server has. - * - * @return array array('rightsEnough' => true|false, 'rightsTooMuch' => true|false, 'rightsMissing' => array, 'rightsNeeded' => array); - */ - public static function getDatabaseUserAccessRights() - { - global $wpdb; - - $rightsNeeded = array('SELECT','INSERT','UPDATE','DELETE','ALTER'); - $data = array( - 'rightsEnough' => false, - 'rightsTooMuch' => false, - 'rightsHaving' => array(), - 'rightsNeeded' => $rightsNeeded - ); - - $rights = $wpdb->get_results("SHOW GRANTS FOR '".DB_USER."'@'".DB_HOST."'", ARRAY_N); - - if (empty($rights)) { - //return $data; - $rights = $wpdb->get_results("SHOW GRANTS FOR current_user()", ARRAY_N); - if(empty($rights)){ - return $data; - } - } - - foreach($rights as $_right) - { - $right = $_right[0]; - //#! no rights - if(preg_match("/GRANT USAGE ON/", $right)){ - continue; - } - //#! way too many. db scope || global scope - $right = str_replace('\\','',$right); - $pattern = "/ALL PRIVILEGES ON `?".preg_quote(DB_NAME)."`?/"; - if(preg_match($pattern, $right) || preg_match("/ALL PRIVILEGES ON \*\./", $right)){ - array_push($rightsNeeded, 'CREATE'); - $data = array( - 'rightsEnough' => true, - 'rightsTooMuch' => true, - 'rightsHaving' => $rightsNeeded, - 'rightsNeeded' => $rightsNeeded - ); - break; - } - //#! more secure. db scope || global scope - elseif(preg_match_all("/GRANT (.*) ON `?".preg_quote(DB_NAME)."`?/",$right,$matches) || preg_match_all("/GRANT (.*) ON \*\./",$right,$matches)){ - if(! empty($matches[1][0])){ - $foundRights = explode(',', $matches[1][0]); - $foundRights = array_map("trim", $foundRights); - $missingRights = array_diff($rightsNeeded, $foundRights); - $data = array( - 'rightsEnough' => (empty($missingRights) ? true : false), - 'rightsTooMuch' => false, - 'rightsHaving' => $foundRights, - 'rightsNeeded' => $rightsNeeded - ); - break; - } - } - } - return $data; - } -} \ No newline at end of file diff --git a/wp-content/plugins/wp-security-scan/res/inc/WsdLiveTraffic.php b/wp-content/plugins/wp-security-scan/res/inc/WsdLiveTraffic.php deleted file mode 100644 index 63da8f71..00000000 --- a/wp-content/plugins/wp-security-scan/res/inc/WsdLiveTraffic.php +++ /dev/null @@ -1,330 +0,0 @@ -query($query); - wssLog("Deleting live traffic entries.", array('query'=>$query, 'result'=>$result)); - return; - } - - $optData = WpsOption::getOption(WpsSettings::LIVE_TRAFFIC_ENTRIES); - if(empty($optData)){ - wssLog("Option (".WpsSettings::LIVE_TRAFFIC_ENTRIES.") not found."); - return; - } - - $numEntries = $wpdb->get_var("SELECT COUNT(entryId) FROM ".WsdPlugin::getTableName(WpsSettings::LIVE_TRAFFIC_TABLE_NAME)); - - if($numEntries <> $keepMaxEntries){ - WpsOption::updateOption(WpsSettings::LIVE_TRAFFIC_ENTRIES, $numEntries); - } - - if(intval($optData) <= $keepMaxEntries){ - return; - } - - $tableName = WsdPlugin::getTableName(WpsSettings::LIVE_TRAFFIC_TABLE_NAME); - - $querySelect = "SELECT min(t.entryTime) - FROM - ( - SELECT - entryTime - FROM - ".$tableName." - ORDER BY - entryTime DESC - LIMIT ".$keepMaxEntries." - ) AS t"; - - - $deleteFromTime = $wpdb->get_var($querySelect); - - $queryDelete = "DELETE FROM ".$tableName." WHERE entryTime < %s"; - $result = $wpdb->query($wpdb->prepare($queryDelete,$deleteFromTime)); - - wssLog("Deleting live traffic entries.", array('query'=>"DELETE FROM $tableName WHERE entryTime < $deleteFromTime", 'deleted'=>$result)); - - if(false === $result){ - return; - } - // update option - $numEntries = $wpdb->get_var("SELECT COUNT(entryId) FROM ".WsdPlugin::getTableName(WpsSettings::LIVE_TRAFFIC_TABLE_NAME)); - WpsOption::updateOption(WpsSettings::LIVE_TRAFFIC_ENTRIES, $numEntries); - } - - final public static function registerHit() - { - // check if live traffic tool is enabled - $liveTrafficToolEnabled = WpsOption::getOption(WpsSettings::ENABLE_LIVE_TRAFFIC); - if(! $liveTrafficToolEnabled){ - return; - } - - if(is_admin()){ return; } - - global $wpdb; - - $blogID = $wpdb->blogid; - $url = self::getRequestedUrl(); - - if(self::isUrlExcluded($url)){ return; } - - $ip = self::getIP(); - $referrer = self::getReferrer(); - $ua = self::getUserAgent(); - - $geoIpInfo = self::_getGeoIpInfo($ip); - $country = $geoIpInfo['country']; - $city = $geoIpInfo['city']; - - $query = $wpdb->prepare("INSERT INTO ".WsdPlugin::getTableName(WpsSettings::LIVE_TRAFFIC_TABLE_NAME)." (entryTime, entryIp, entryReferrer, entryUA, entryRequestedUrl, entryCountry, entryCity, blogId) - VALUES(CURRENT_TIMESTAMP, %s, %s, %s, %s, %s, %s, %d)", $ip, $referrer, $ua, $url, $country, $city, $blogID); - if(false === @$wpdb->query($query)){ - return; - } - - $numEvents = 0; - $optData = WpsOption::getOption(WpsSettings::LIVE_TRAFFIC_ENTRIES); - if(empty($optData)){ - WpsOption::addOption(WpsSettings::LIVE_TRAFFIC_ENTRIES, $numEvents); - } - else { $numEvents = intval($optData); } - - WpsOption::updateOption(WpsSettings::LIVE_TRAFFIC_ENTRIES, $numEvents + 1); - } - - final public static function getIP() - { - $ip = null; - if ( isset($_SERVER["REMOTE_ADDR"]) ) { $ip = $_SERVER["REMOTE_ADDR"]; } - else if ( isset($_SERVER["HTTP_X_FORWARDED_FOR"]) ) { $ip = $_SERVER["HTTP_X_FORWARDED_FOR"]; } - else if ( isset($_SERVER["HTTP_CLIENT_IP"]) ) { $ip = $_SERVER["HTTP_CLIENT_IP"]; } - if(! is_null($ip) && self::isValidIp($ip)){ return $ip; } - return 'unknown'; - } - - final public static function getReferrer() { return (empty($_SERVER['HTTP_REFERER']) ? '' : htmlentities($_SERVER['HTTP_REFERER'],ENT_QUOTES)); } - - final public static function getUserAgent() { return (empty($_SERVER['HTTP_USER_AGENT']) ? '' : htmlentities($_SERVER['HTTP_USER_AGENT'],ENT_QUOTES)); } - - final public static function isValidIp($ip){ - if(preg_match('/^(\d+)\.(\d+)\.(\d+)\.(\d+)$/', $ip, $m)){ - if( - $m[0] >= 0 && $m[0] <= 255 && - $m[1] >= 0 && $m[1] <= 255 && - $m[2] >= 0 && $m[2] <= 255 && - $m[3] >= 0 && $m[3] <= 255 - ){ - return true; - } - } - return false; - } - final public static function getRequestedUrl(){ - if(isset($_SERVER['HTTP_HOST']) && $_SERVER['HTTP_HOST']){ - $host = $_SERVER['HTTP_HOST']; } - else { - $host = $_SERVER['SERVER_NAME']; - } - $url = (isset($_SERVER['HTTPS']) ? 'https' : 'http') . '://' . $host . $_SERVER['REQUEST_URI']; - return esc_url($url); - } - - /** - * @param int $maxEntries If $maxEntries is 0 it means to load all entries, otherwise it will limit the select to that number - * @return mixed - */ - final public static function getTrafficData($maxEntries = 0) - { - global $wpdb; - if(empty($maxEntries)){ - return $wpdb->get_results("SELECT entryId,entryTime,entryIp,entryReferrer,entryUA,entryRequestedUrl,entryCountry,entryCity FROM ".WsdPlugin::getTableName(WpsSettings::LIVE_TRAFFIC_TABLE_NAME)." ORDER BY entryId DESC"); - } - else { return $wpdb->get_results("SELECT entryId,entryTime,entryIp,entryReferrer,entryUA,entryRequestedUrl,entryCountry,entryCity FROM ".WsdPlugin::getTableName(WpsSettings::LIVE_TRAFFIC_TABLE_NAME)." ORDER BY entryId DESC LIMIT 0, ".$maxEntries);} - } - - final public static function getLastID() - { - global $wpdb; - return $wpdb->get_var("SELECT entryId FROM ".WsdPlugin::getTableName(WpsSettings::LIVE_TRAFFIC_TABLE_NAME)." ORDER BY entryId DESC"); - } - - final public static function ajaxGetTrafficData() - { - if(! isset($_REQUEST['nonce'])){ exit('Invalid request'); } - if ( !wp_verify_nonce( $_REQUEST['nonce'], "wpsTrafficScan_nonce")) { exit('Invalid request'); } - - if ( !isset( $_REQUEST['getFrom'])) { exit(__('Invalid request',WpsSettings::TEXT_DOMAIN)); } - if ( !isset( $_REQUEST['maxEntries'])) { exit(__('Invalid request',WpsSettings::TEXT_DOMAIN)); } - - $lastID = intval($_REQUEST['getFrom']); - $maxEntries = intval($_REQUEST['maxEntries']); - - if(!empty($_SERVER['HTTP_X_REQUESTED_WITH']) && strtolower($_SERVER['HTTP_X_REQUESTED_WITH']) == 'xmlhttprequest') - { - echo self::_ajaxGetFrom($maxEntries, $lastID); - exit; - } - exit('Invalid request!'); - } - - /** - * @internal - * @param $maxEntries - * @param int $lastID - * @return mixed|string|void - */ - final public static function _ajaxGetFrom($maxEntries, $lastID = 0) - { - $result = array( - 'type' => 'success', - 'data' => array() - ); - - // get the last ID from db - $dbLastID = self::getLastID(); - - if(empty($dbLastID)){ - $result['data'][] = '

'.__('No data yet.',WpsSettings::TEXT_DOMAIN).'

'; - return json_encode($result); - } - - // no change - nothing to display - if($lastID == $dbLastID) - { - return json_encode($result); - } - - if($lastID == 0){ - $getFrom = $maxEntries; - } - else { - $getFrom = $dbLastID - $lastID; - if ($getFrom < 1){ - return json_encode($result); - } - } - - $data = self::getTrafficData($getFrom); - if(empty($data)){ $result['data'][] = '

'.__('No data yet.',WpsSettings::TEXT_DOMAIN).'

'; } - else { - $data = array_reverse($data); - foreach($data as $entry) - { - $req = trim($entry->entryRequestedUrl); - $e = ''; - $e .= '
'; - if(empty($entry->entryReferrer)){ - $ref = ''; - } - else { - // Ignore page refresh - $ref = trim($entry->entryReferrer); - if(strcasecmp($req,$ref)==0){ - continue; - } - $url = strip_tags(urldecode($req)); - $url = esc_html($url,ENT_QUOTES); - $ref = ' '.__('coming from',WpsSettings::TEXT_DOMAIN).' '. $url . ''; - } - - // add geo-location + flag - $country = ''; - $city = ''; - $flag = ''; - - if(!empty($entry->entryCountry)){ - $country = $entry->entryCountry; - $pos = strpos($country,','); - if(false !== $pos){ - $code = substr($country, $pos+1); - $flag = WsdUtil::imageUrl('flags/'.strtolower($code).'.png'); - $country = substr($country, 0, $pos); - } - } - if(!empty($entry->entryCity)){ $city = $entry->entryCity; } - if(!empty($flag)) - { - $flag = trim($flag); - if(false !== ($pos = strpos($flag, ' republic of,kr.png'))){ - $flag = WsdUtil::imageUrl('flags/kr.png'); - } - $flag = ''.$flag.''; - } - - $ipInfoUrl = "http://dnsquery.org/ipwhois/{$entry->entryIp}"; - $ipInfoTitle = __('Lookup this IP. Opens in a new window/tab',WpsSettings::TEXT_DOMAIN); - - $geoInfo = ''; - if(! empty($country)){ - if(! empty($flag)){ $geoInfo .= $flag; } - if(! empty($city)) { $geoInfo .= ' '.$city.',';} - if(! empty($country)) { $geoInfo .= ' '.$country; } - $geoInfo .= ' ('.$entry->entryIp.')'; - } - else { $geoInfo = __('Unknown location',WpsSettings::TEXT_DOMAIN).' ('.$entry->entryIp.')'; } - $geoInfo .= ''; - - $reqUrl = strip_tags(urldecode($req)); - $reqUrl = esc_html($reqUrl,ENT_QUOTES); - $e .= '

'.$geoInfo; - $e .= $ref.' '.__('requested',WpsSettings::TEXT_DOMAIN).' '.$reqUrl.'

'; - $e .= '

'.__('Date',WpsSettings::TEXT_DOMAIN).': '.$entry->entryTime.'

'; - $e .= '

'.__('Agent',WpsSettings::TEXT_DOMAIN).': '.htmlentities($entry->entryUA,ENT_QUOTES).'

'; - $e .= '
'; - $e .= ''; - $result['data'][] = $e; - } - } - return json_encode($result); - } - - /** - * @param $url - * @return bool - * Exclude urls - */ - private static function isUrlExcluded($url) - { - if(false !==(strpos($url, 'wp-cron.php?doing_wp_cron'))) { return true; } - return false; - } - - private static function _getGeoIpInfo($ip) - { - $data = array( - 'country' => '', - 'city' => '' - ); - if($ip == '0.0.0.0'){ - return $data; - } - - $infoUrl = 'http://www.geoplugin.net/json.gp?ip='.$ip; - $result = @file_get_contents($infoUrl); - if(empty($result)){ - return $data; - } - $result = json_decode($result); - $data['country'] = $result->geoplugin_countryName. (empty($result->geoplugin_countryCode) ? '' : sanitize_text_field(','.$result->geoplugin_countryCode)); - $data['city'] = (empty($result->geoplugin_city) ? '' : sanitize_text_field($result->geoplugin_city)); - return $data; - } - -} diff --git a/wp-content/plugins/wp-security-scan/res/inc/WsdPlugin.php b/wp-content/plugins/wp-security-scan/res/inc/WsdPlugin.php deleted file mode 100644 index ccb9388c..00000000 --- a/wp-content/plugins/wp-security-scan/res/inc/WsdPlugin.php +++ /dev/null @@ -1,710 +0,0 @@ -get_var("SELECT alertFirstSeen FROM $table WHERE alertActionName = '$actionName' ORDER BY `alertDate`;"); - if(empty($afsDate)){ $afsDate = "CURRENT_TIMESTAMP()";} - else { $afsDate = "'".$afsDate."'"; } - $result = $wpdb->get_var("SELECT COUNT(alertId) FROM $table WHERE alertActionName = '$actionName';"); - if($result >= WpsSettings::ALERT_STACK_MAX_KEEP){ - // remove older entries to make room for the new ones - $query = "DELETE FROM $table ORDER BY alertDate ASC LIMIT ".($result - (WpsSettings::ALERT_STACK_MAX_KEEP - 1)); - $wpdb->query($query); - } - - //Add the new entry - $query = $wpdb->prepare( - "INSERT INTO $table - (`alertType`, - `alertSeverity`, - `alertActionName`, - `alertTitle`, - `alertDescription`, - `alertSolution`, - `alertDate`, - `alertFirstSeen`) - VALUES - (%d, - %d, - '%s', - '%s', - '%s', - '%s', - CURRENT_TIMESTAMP(), - $afsDate - );", - $type, $severity, $actionName, $title, $description, $solution); - } - elseif($type == WpsSettings::ALERT_TYPE_OVERWRITE) - { - //#! Find the record by actionName and update fields - $result = $wpdb->get_var("SELECT alertId FROM $table WHERE alertActionName = '".$actionName."'; "); - //#! found. do update - if($result > 0){ - $query = $wpdb->prepare("UPDATE $table - SET - `alertType` = %d, - `alertSeverity` = %d, - `alertActionName` = '%s', - `alertTitle` = '%s', - `alertDescription` = '%s', - `alertSolution` = '%s', - `alertDate` = CURRENT_TIMESTAMP() - WHERE alertId = %d;", - $type, $severity, $actionName, $title, $description, $solution,$result); - } - //#! record not found. insert query - else { - $query = $wpdb->prepare("INSERT INTO $table - (`alertType`, - `alertSeverity`, - `alertActionName`, - `alertTitle`, - `alertDescription`, - `alertSolution`, - `alertDate`, - `alertFirstSeen`) - VALUES - (%d, - %d, - '%s', - '%s', - '%s', - '%s', - CURRENT_TIMESTAMP(), - CURRENT_TIMESTAMP() - );", - $type, $severity, $actionName, $title, $description, $solution); - } - } - $result = $wpdb->query($query); - if($result === false){ - //#! MySQL error - return false; - } - return true; - } - - public static function getTableName($tableName = WpsSettings::ALERTS_TABLE_NAME){ - return wpsGetBasePrefix().$tableName; - } - - /** - * Get all alerts grouped by alertActionName - * @return array - */ - public static function getAlerts() - { - global $wpdb; - $columns = "`alertId`,`alertType`,`alertSeverity`,`alertActionName`,`alertTitle`,`alertDescription`,`alertSolution`,`alertDate`,`alertFirstSeen`"; - return $wpdb->get_results("SELECT $columns FROM ".self::getTableName(WpsSettings::ALERTS_TABLE_NAME)." GROUP BY `alertActionName`;"); - } - - // filter alerts by input - public static function getAlertsBy($alertSeverity) - { - global $wpdb; - $columns = "`alertId`,`alertType`,`alertSeverity`,`alertActionName`,`alertTitle`,`alertDescription`,`alertSolution`,`alertDate`,`alertFirstSeen`"; - return $wpdb->get_results("SELECT $columns FROM ".self::getTableName(WpsSettings::ALERTS_TABLE_NAME)." WHERE `alertSeverity` = '$alertSeverity' GROUP BY `alertActionName`;"); - } - - public static function getChildAlerts($alertId, $alertType) - { - global $wpdb; - $columns = "`alertId`,`alertType`,`alertSeverity`,`alertActionName`,`alertTitle`,`alertDescription`,`alertSolution`,`alertDate`,`alertFirstSeen`"; - return $wpdb->get_results("SELECT $columns FROM ".self::getTableName()." WHERE (alertId <> $alertId AND alertType = '$alertType') ORDER BY `alertDate` DESC"); - } - - /** - * Retrieve the settings from database. This method will extract all methods found in the WsdSecurity class and provide them as - * settings in the settings page. It will also auto update itself in case new methods are added to the class or if - * some of them were removed. - * @return array - */ - public static function getSettings() - { - $className = 'WsdSecurity'; - if(! class_exists($className)){ - return array(); - } - - if(wpsIsMultisite()){ - $settings = get_blog_option(1, WpsSettings::PLUGIN_SETTINGS_OPTION_NAME); - } - else { $settings = WpsOption::getOption(WpsSettings::PLUGIN_SETTINGS_OPTION_NAME); } - - $methods = WpsSettings::getSettingsList(); - $useReflection = false; - - if(empty($settings)) - { - $settings = array(); - foreach($methods as $method) - { - $settings[$method['name']] = array( - 'name' => $method['name'], - 'value' => 0, // 0 or 1 ; whether or not the option will show as selected by default in the plugin's settings page - 'desc' => $method['text'] - ); - } - } - else - { - // Check to see whether or not new methods were added or subtracted - $numSettings = count($settings); - $numMethods = count($methods); - if($numMethods <> $numSettings) - { - // add new methods - $_temp = array(); - foreach($methods as $method) - { - if(! isset($settings[$method['name']])){ - $settings[$method['name']] = array( - 'name' => $method['name'], - 'value' => 0, - 'desc' => $method['text'] - ); - } - array_push($_temp, $method['name']); - } - // remove missing methods - foreach($settings as $k => &$entry){ - if(! in_array($entry['name'], $_temp)){ - unset($settings[$k]); - } - } - } - } - WpsOption::addOption(WpsSettings::PLUGIN_SETTINGS_OPTION_NAME, $settings); - return $settings; - } - - /** - * Check to see whether or not the provided setting is enabled (as the settings are configurable the user might chose to turn some of them off) - * @param string $name The name of the setting to look for in the settings array - * @return bool - */ - public static function isSettingEnabled($name) - { - $settings = self::getSettings(); - return (isset($settings[$name]) ? $settings[$name]['value'] : false); - } - - - static function networkActivate() - { - wssLog(__METHOD__.'() executed'); - global $wpdb; - $charset_collate = ''; - - if ( ! empty($wpdb->charset) ){$charset_collate = "DEFAULT CHARACTER SET $wpdb->charset";} - if ( ! empty($wpdb->collate) ){$charset_collate .= " COLLATE $wpdb->collate";} - - // MUST HAVE "CREATE" RIGHTS if a table is not found and needs to be created - $rights = WsdInfoServer::getDatabaseUserAccessRights(); - $hasCreateRight = in_array('CREATE', $rights['rightsHaving']); - // Must have alter right for updating table - $hasAlterRight = in_array('CREATE', $rights['rightsHaving']); - $table1 = self::getTableName(WpsSettings::ALERTS_TABLE_NAME); - $table2 = self::getTableName(WpsSettings::LIVE_TRAFFIC_TABLE_NAME); - $table3 = self::getTableName(WpsSettings::SCAN_TABLE_NAME); - $table4 = self::getTableName(WpsSettings::SCANS_TABLE_NAME); - - $notices = get_blog_option(1, WpsSettings::PLUGIN_ERROR_NOTICE_OPTION, array()); - - if(! WsdUtil::tableExists($table1)){ - wssLog("table not found: $table1"); - if(! $hasCreateRight){ - $notices[] = ''.WPS_PLUGIN_NAME.": The database user needs the 'CREATE' right in order to install this plugin."; - update_site_option(WpsSettings::PLUGIN_ERROR_NOTICE_OPTION, $notices); - return false; - } - $query1 = "CREATE TABLE IF NOT EXISTS $table1 ( - `alertId` INT UNSIGNED NOT NULL AUTO_INCREMENT , - `alertType` TINYINT NOT NULL DEFAULT 0 , - `alertSeverity` INT NOT NULL DEFAULT 0 , - `alertActionName` VARCHAR (255) NOT NULL, - `alertTitle` VARCHAR(255) NOT NULL , - `alertDescription` TEXT NOT NULL , - `alertSolution` TEXT NOT NULL , - `alertDate` DATETIME NOT NULL default '0000-00-00 00:00:00', - `alertFirstSeen` DATETIME NOT NULL default '0000-00-00 00:00:00', - PRIMARY KEY (`alertId`) , - UNIQUE INDEX `alertId_UNIQUE` (`alertId` ASC) ) $charset_collate;"; - $result = @$wpdb->query($query1); - if($result === false){ - //#! MySQL error - $notices[]= ''.WPS_PLUGIN_NAME.". Error running query:
$query1
."; - update_site_option(WpsSettings::PLUGIN_ERROR_NOTICE_OPTION, $notices); - return false; - } - wssLog("table created: $table1"); - } - - $alterCheck = true; - if(! WsdUtil::tableExists($table2)){ - wssLog("table not found: $table2"); - if(! $hasCreateRight){ - $notices[]= ''.WPS_PLUGIN_NAME.": The database user needs the 'CREATE' right in order to install this plugin."; - update_site_option(WpsSettings::PLUGIN_ERROR_NOTICE_OPTION, $notices); - return false; - } - $query2 = "CREATE TABLE IF NOT EXISTS $table2 ( - `entryId` bigint(20) unsigned NOT NULL auto_increment, - `entryTime` datetime NOT NULL DEFAULT '0000-00-00 00:00:00', - `entryIp` text, - `entryReferrer` text, - `entryUA` text, - `entryRequestedUrl` text, - `entryCountry` varchar(125) not null, - `entryCity` varchar(125) not null, - `blogId` INT(10) NOT NULL DEFAULT 1, - PRIMARY KEY (entryId)) $charset_collate;"; - $result = @$wpdb->query($query2); - if($result === false){ - //#! MySQL error - $notices[]= ''.WPS_PLUGIN_NAME.". Error running query:
$query2
."; - update_site_option(WpsSettings::PLUGIN_ERROR_NOTICE_OPTION, $notices); - return false; - } - $alterCheck = false; - wssLog("table created: $table2."); - } - - if($alterCheck) - { - wssLog("Alter check needed for $table2."); - if(! $hasAlterRight){ - $notices[]= ''.WPS_PLUGIN_NAME.": The database user needs the 'ALTER' right in order to install this plugin."; - update_site_option(WpsSettings::PLUGIN_ERROR_NOTICE_OPTION, $notices); - return false; - } - - // Get columns - $query = "SHOW COLUMNS FROM $table2"; - $cols = $wpdb->get_results($query, ARRAY_A); - $columns = array(); - if(empty($cols)){ - wssLog("Could not retrieve columns from table: $table2"); - $notices[]= ''.WPS_PLUGIN_NAME.". Error running query:
$query
. Please inform the plugin author about this error."; - WpsOption::updateOption(WpsSettings::PLUGIN_ERROR_NOTICE_OPTION, $notices); - return false; - } - foreach($cols as $i => $values){ - if(isset($values['Field']) && !empty($values['Field'])){ - array_push($columns, $values['Field']); - } - } - $entryCountryExists = $entryCityExists = $blogIdExists = false; - if(in_array('entryCountry', $columns)){ $entryCountryExists = true; } - if(in_array('entryCity', $columns)){ $entryCityExists = true; } - if(in_array('blogId', $columns)){ $blogIdExists = true; } - - //## Check for column: entryCountry - wssLog("Checking for column: entryCountry"); - if(!$entryCountryExists) - { - // alter table - $q = "ALTER TABLE $table2 ADD COLUMN `entryCountry` VARCHAR(125) NOT NULL DEFAULT '' AFTER `entryRequestedUrl`;"; - $result = @$wpdb->query($q); - if($result === false){ - //#! MySQL error - $notices[]= ''.WPS_PLUGIN_NAME.". Error running query:
$q
."; - update_site_option(WpsSettings::PLUGIN_ERROR_NOTICE_OPTION, $notices); - return false; - } - } - - //## Check for column: entryCity - wssLog("Checking for column: entryCity"); - if(!$entryCityExists) - { - $q = "ALTER TABLE $table2 ADD COLUMN `entryCity` VARCHAR(125) NOT NULL DEFAULT '' AFTER `entryCountry`;"; - $result = @$wpdb->query($q); - if($result === false){ - //#! MySQL error - $notices[]= ''.WPS_PLUGIN_NAME.". Error running query:
$q
."; - update_site_option(WpsSettings::PLUGIN_ERROR_NOTICE_OPTION, $notices); - return false; - } - } - - //## Check for column: blogId - wssLog("Checking for column: blogid"); - if(!$blogIdExists) - { - $q = "ALTER TABLE $table2 ADD COLUMN `blogId` INT(10) NOT NULL DEFAULT 1 AFTER `entryCity`;"; - $result = @$wpdb->query($q); - if($result === false){ - //#! MySQL error - $notices[]= ''.WPS_PLUGIN_NAME.". Error running query:
$q
."; - update_site_option(WpsSettings::PLUGIN_ERROR_NOTICE_OPTION, $notices); - return false; - } - } - wssLog("$table2 updated successfully"); - } - - if(! WsdUtil::tableExists($table3)){ - wssLog("table not found: $table3"); - if(! $hasCreateRight){ - $notices[]= ''.WPS_PLUGIN_NAME.": The database user needs the 'CREATE' right in order to install this plugin."; - update_site_option(WpsSettings::PLUGIN_ERROR_NOTICE_OPTION, $notices); - return false; - } - $query3 = "CREATE TABLE IF NOT EXISTS $table3 ( - `entryId` BIGINT NOT NULL AUTO_INCREMENT , - `scanId` INT NOT NULL , - `filePath` VARCHAR(1000) NOT NULL , - `dateModified` DATETIME NOT NULL DEFAULT '0000-00-00 00:00:00' , - `fileNotFound` TINYINT NOT NULL DEFAULT 0, - PRIMARY KEY (`entryId`) , - UNIQUE INDEX `entryId_UNIQUE` (`entryId` ASC) ) $charset_collate;"; - $result = @$wpdb->query($query3); - if($result === false){ - //#! MySQL error - $notices[]= ''.WPS_PLUGIN_NAME.". Error running query:
$query3
."; - update_site_option(WpsSettings::PLUGIN_ERROR_NOTICE_OPTION, $notices); - return false; - } - } - - if(! WsdUtil::tableExists($table4)){ - wssLog("table not found: $table4"); - if(! $hasCreateRight){ - $notices[]= ''.WPS_PLUGIN_NAME.": The database user needs the 'CREATE' right in order to install this plugin."; - WpsOption::updateOption(WpsSettings::PLUGIN_ERROR_NOTICE_OPTION, $notices); - return false; - } - $query4 = "CREATE TABLE $table4 ( - `scanId` INT NOT NULL AUTO_INCREMENT , - `scanStartDate` DATETIME NOT NULL DEFAULT '0000-00-00 00:00:00', - `scanEndDate` DATETIME NOT NULL DEFAULT '0000-00-00 00:00:00', - `scanResult` INT NOT NULL DEFAULT 0, - `failReason` VARCHAR(5000) NOT NULL DEFAULT '', - `scanType` int(11) NOT NULL DEFAULT '0', - PRIMARY KEY (`scanId`) ) $charset_collate;"; - $result = @$wpdb->query($query4); - if($result === false){ - //#! MySQL error - $notices[]= ''.WPS_PLUGIN_NAME.". Error running query:
$query4
."; - update_site_option(WpsSettings::PLUGIN_ERROR_NOTICE_OPTION, $notices); - return false; - } - } - add_blog_option($wpdb->blogid, WpsSettings::CAN_RUN_TASKS_OPTION_NAME, 1); - return true; - } - - static function activate() - { - wssLog(__METHOD__.'() executed'); - global $wpdb; - $charset_collate = ''; - - if ( ! empty($wpdb->charset) ){$charset_collate = "DEFAULT CHARACTER SET $wpdb->charset";} - if ( ! empty($wpdb->collate) ){$charset_collate .= " COLLATE $wpdb->collate";} - - // MUST HAVE "CREATE" RIGHTS if a table is not found and needs to be created - $rights = WsdInfoServer::getDatabaseUserAccessRights(); - wssLog('USER RIGHTS', $rights); - $hasCreateRight = in_array('CREATE', $rights['rightsHaving']); - // Must have alter right for updating table - $hasAlterRight = in_array('CREATE', $rights['rightsHaving']); - $table1 = self::getTableName(WpsSettings::ALERTS_TABLE_NAME); - $table2 = self::getTableName(WpsSettings::LIVE_TRAFFIC_TABLE_NAME); - $table3 = self::getTableName(WpsSettings::SCAN_TABLE_NAME); - $table4 = self::getTableName(WpsSettings::SCANS_TABLE_NAME); - - if(! WsdUtil::tableExists($table1)){ - wssLog("table not found: $table1"); - if(! $hasCreateRight){ - wssLog("user has no create right. cannot create table: $table1"); - $notices = WpsOption::getOption(WpsSettings::PLUGIN_ERROR_NOTICE_OPTION, array()); - $notices[]= ''.WPS_PLUGIN_NAME.": The database user needs the 'CREATE' right in order to install this plugin."; - WpsOption::updateOption(WpsSettings::PLUGIN_ERROR_NOTICE_OPTION, $notices); - return false; - } - $query1 = "CREATE TABLE IF NOT EXISTS $table1 ( - `alertId` INT UNSIGNED NOT NULL AUTO_INCREMENT , - `alertType` TINYINT NOT NULL DEFAULT 0 , - `alertSeverity` INT NOT NULL DEFAULT 0 , - `alertActionName` VARCHAR (255) NOT NULL, - `alertTitle` VARCHAR(255) NOT NULL , - `alertDescription` TEXT NOT NULL , - `alertSolution` TEXT NOT NULL , - `alertDate` DATETIME NOT NULL default '0000-00-00 00:00:00', - `alertFirstSeen` DATETIME NOT NULL default '0000-00-00 00:00:00', - PRIMARY KEY (`alertId`) , - UNIQUE INDEX `alertId_UNIQUE` (`alertId` ASC) ) $charset_collate;"; - $result = @$wpdb->query($query1); - if($result === false){ - //#! MySQL error - $notices= WpsOption::getOption(WpsSettings::PLUGIN_ERROR_NOTICE_OPTION, array()); - $notices[]= ''.WPS_PLUGIN_NAME.". Error running query:
$query1
."; - WpsOption::updateOption(WpsSettings::PLUGIN_ERROR_NOTICE_OPTION, $notices); - return false; - } - wssLog("table created: $table1"); - } - - $alterCheck = true; - if(! WsdUtil::tableExists($table2)){ - wssLog("table not found: $table2"); - if(! $hasCreateRight){ - $notices= WpsOption::getOption(WpsSettings::PLUGIN_ERROR_NOTICE_OPTION, array()); - $notices[]= ''.WPS_PLUGIN_NAME.": The database user needs the 'CREATE' right in order to install this plugin."; - WpsOption::updateOption(WpsSettings::PLUGIN_ERROR_NOTICE_OPTION, $notices); - return false; - } - $query2 = "CREATE TABLE IF NOT EXISTS $table2 ( - `entryId` bigint(20) unsigned NOT NULL auto_increment, - `entryTime` datetime NOT NULL DEFAULT '0000-00-00 00:00:00', - `entryIp` text, - `entryReferrer` text, - `entryUA` text, - `entryRequestedUrl` text, - `entryCountry` varchar(125) not null, - `entryCity` varchar(125) not null, - `blogId` INT(10) NOT NULL DEFAULT 1, - PRIMARY KEY (entryId)) $charset_collate;"; - $result = @$wpdb->query($query2); - if($result === false){ - //#! MySQL error - $notices= WpsOption::getOption(WpsSettings::PLUGIN_ERROR_NOTICE_OPTION, array()); - $notices[]= ''.WPS_PLUGIN_NAME.". Error running query:
$query2
."; - WpsOption::updateOption(WpsSettings::PLUGIN_ERROR_NOTICE_OPTION, $notices); - return false; - } - $alterCheck = false; - wssLog("table created: $table2."); - } - - if($alterCheck) - { - wssLog("Alter check needed for $table2."); - if(! $hasAlterRight){ - wssLog('NO ALTER RIGHT'); - $notices[]= ''.WPS_PLUGIN_NAME.": The database user needs the 'ALTER' right in order to install this plugin."; - WpsOption::updateOption(WpsSettings::PLUGIN_ERROR_NOTICE_OPTION, $notices); - return false; - } - - // Get columns - $query = "SHOW COLUMNS FROM $table2"; - $cols = $wpdb->get_results($query, ARRAY_A); - $columns = array(); - if(empty($cols)){ - wssLog("Could not retrieve columns from table: $table2"); - $notices[]= ''.WPS_PLUGIN_NAME.". Error running query:
$query
. Please inform the plugin author about this error."; - WpsOption::updateOption(WpsSettings::PLUGIN_ERROR_NOTICE_OPTION, $notices); - return false; - } - foreach($cols as $i => $values){ - if(isset($values['Field']) && !empty($values['Field'])){ - array_push($columns, $values['Field']); - } - } - $entryCountryExists = $entryCityExists = $blogIdExists = false; - if(in_array('entryCountry', $columns)){ $entryCountryExists = true; } - if(in_array('entryCity', $columns)){ $entryCityExists = true; } - if(in_array('blogId', $columns)){ $blogIdExists = true; } - -//## Check for column: entryCountry - wssLog("Checking for column: entryCountry"); - if(!$entryCountryExists) - { - // alter table - $q = "ALTER TABLE $table2 ADD COLUMN `entryCountry` VARCHAR(125) NOT NULL DEFAULT '' AFTER `entryRequestedUrl`;"; - $result = @$wpdb->query($q); - if($result === false){ - wssLog('MySql error: '.mysql_error()); - wssLog("Error running query: $q"); - //#! MySQL error - $notices[]= ''.WPS_PLUGIN_NAME.". Error running query:
$q
."; - WpsOption::updateOption(WpsSettings::PLUGIN_ERROR_NOTICE_OPTION, $notices); - return false; - } - wssLog("Column: entryCountry not found in table $table2. but was added."); - } - else { wssLog("column already exists: entryCountry");} - -//## Check for column: entryCity - wssLog("Checking for column: entryCity"); - if(!$entryCityExists) - { - $q = "ALTER TABLE $table2 ADD COLUMN `entryCity` VARCHAR(125) NOT NULL DEFAULT '' AFTER `entryCountry`;"; - $result = @$wpdb->query($q); - if($result === false){ - //#! MySQL error - $notices[]= ''.WPS_PLUGIN_NAME.". Error running query:
$q
."; - WpsOption::updateOption(WpsSettings::PLUGIN_ERROR_NOTICE_OPTION, $notices); - return false; - } - wssLog("Column: entryCity not found in table $table2. but was added."); - } - else { wssLog("column already exists: entryCity");} - -//## Check for column: blogId - wssLog("Checking for column: blogId"); - if(!$blogIdExists) - { - $q = "ALTER TABLE $table2 ADD COLUMN `blogId` INT(10) NOT NULL DEFAULT 1 AFTER `entryCity`;"; - $result = @$wpdb->query($q); - if($result === false){ - //#! MySQL error - $notices[]= ''.WPS_PLUGIN_NAME.". Error running query:
$q
."; - WpsOption::updateOption(WpsSettings::PLUGIN_ERROR_NOTICE_OPTION, $notices); - return false; - } - wssLog("Column: blogId not found in table $table2. but was added."); - } - else { wssLog("column already exists: blogid");} - wssLog("$table2 updated successfully"); - } - - if(! WsdUtil::tableExists($table3)){ - wssLog("table not found: $table3"); - if(! $hasCreateRight){ - $notices= WpsOption::getOption(WpsSettings::PLUGIN_ERROR_NOTICE_OPTION, array()); - $notices[]= ''.WPS_PLUGIN_NAME.": The database user needs the 'CREATE' right in order to install this plugin."; - WpsOption::updateOption(WpsSettings::PLUGIN_ERROR_NOTICE_OPTION, $notices); - return false; - } - $query3 = "CREATE TABLE IF NOT EXISTS $table3 ( - `entryId` BIGINT NOT NULL AUTO_INCREMENT , - `scanId` INT NOT NULL , - `filePath` VARCHAR(1000) NOT NULL , - `dateModified` DATETIME NOT NULL DEFAULT '0000-00-00 00:00:00' , - `fileNotFound` TINYINT NOT NULL DEFAULT 0, - PRIMARY KEY (`entryId`) , - UNIQUE INDEX `entryId_UNIQUE` (`entryId` ASC) ) $charset_collate;"; - $result = @$wpdb->query($query3); - if($result === false){ - //#! MySQL error - $notices= WpsOption::getOption(WpsSettings::PLUGIN_ERROR_NOTICE_OPTION, array()); - $notices[]= ''.WPS_PLUGIN_NAME.". Error running query:
$query3
."; - WpsOption::updateOption(WpsSettings::PLUGIN_ERROR_NOTICE_OPTION, $notices); - return false; - } - wssLog("table created: $table3."); - } - - if(! WsdUtil::tableExists($table4)){ - wssLog("table not found: $table4"); - if(! $hasCreateRight){ - $notices= WpsOption::getOption(WpsSettings::PLUGIN_ERROR_NOTICE_OPTION, array()); - $notices[]= ''.WPS_PLUGIN_NAME.": The database user needs the 'CREATE' right in order to install this plugin."; - WpsOption::updateOption(WpsSettings::PLUGIN_ERROR_NOTICE_OPTION, $notices); - return false; - } - $query4 = "CREATE TABLE $table4 ( - `scanId` INT NOT NULL AUTO_INCREMENT , - `scanStartDate` DATETIME NOT NULL DEFAULT '0000-00-00 00:00:00', - `scanEndDate` DATETIME NOT NULL DEFAULT '0000-00-00 00:00:00', - `scanResult` INT NOT NULL DEFAULT 0, - `failReason` VARCHAR(5000) NOT NULL DEFAULT '', - `scanType` int(11) NOT NULL DEFAULT '0', - PRIMARY KEY (`scanId`) ) $charset_collate;"; - $result = @$wpdb->query($query4); - if($result === false){ - //#! MySQL error - $notices= WpsOption::getOption(WpsSettings::PLUGIN_ERROR_NOTICE_OPTION, array()); - $notices[]= ''.WPS_PLUGIN_NAME.". Error running query:
$query4
."; - WpsOption::updateOption(WpsSettings::PLUGIN_ERROR_NOTICE_OPTION, $notices); - return false; - } - } - WpsOption::addOption(WpsSettings::CAN_RUN_TASKS_OPTION_NAME, 1); - return true; - } - /**@deprecated*/ - public static function deactivate($blogId=1) - { - WsdScheduler::unregisterCronTasks(); - delete_option(WpsSettings::WP_FILE_SCAN_OPTION_NAME); - delete_option(WpsSettings::PLUGIN_ERROR_NOTICE_OPTION); - delete_option(WpsSettings::PLUGIN_SETTINGS_OPTION_NAME); - delete_option(WpsSettings::PLUGIN_ERROR_NOTICE_OPTION); - delete_option(WpsSettings::CAN_RUN_TASKS_OPTION_NAME); - } - public static function uninstall() - { - WpsOption::deleteOption(WpsSettings::LIVE_TRAFFIC_ENTRIES); - WpsOption::deleteOption('WPS_KEEP_NUM_ENTRIES_LT'); - WpsOption::deleteOption('WPS_REFRESH_RATE_AJAX_LT'); - WpsOption::deleteOption(WpsSettings::PLUGIN_SETTINGS_OPTION_NAME); - global $wpdb; - $wpdb->query("DROP TABLE IF EXISTS ".WsdPlugin::getTableName(WpsSettings::SCAN_TABLE_NAME)); - $wpdb->query("DROP TABLE IF EXISTS ".WsdPlugin::getTableName(WpsSettings::SCANS_TABLE_NAME)); - $wpdb->query("DROP TABLE IF EXISTS ".WsdPlugin::getTableName(WpsSettings::ALERTS_TABLE_NAME)); - $wpdb->query("DROP TABLE IF EXISTS ".WsdPlugin::getTableName(WpsSettings::LIVE_TRAFFIC_TABLE_NAME)); - } - - /** - * Check to see whether or not the Secure WordPress plugin is installed - * @return bool - */ - public static function swpPluginInstalled() - { - $pluginPath = trailingslashit(ABSPATH).'wp-content/plugins/secure-wordpress'; - return (is_dir($pluginPath) ? true : false); - } -} \ No newline at end of file diff --git a/wp-content/plugins/wp-security-scan/res/inc/WsdScheduler.php b/wp-content/plugins/wp-security-scan/res/inc/WsdScheduler.php deleted file mode 100644 index 518fa9f7..00000000 --- a/wp-content/plugins/wp-security-scan/res/inc/WsdScheduler.php +++ /dev/null @@ -1,88 +0,0 @@ - run callback - if(! self::canRegisterCronTask()){ - self::registerTask($callback); - return; - } - $interval = strtolower($interval); - if(empty($interval)){ $interval = 'daily'; } - else{ - // check to see if the time interval is valid - $timeIntervals = wp_get_schedules(); - if(! array_key_exists($interval, $timeIntervals)){ - $interval = 'daily'; - } - } - // avoid duplicate crons - add_action($cronActionName, $callback); - if ( ! wp_next_scheduled($cronActionName) ) { - wp_schedule_event( time(), $interval, $cronActionName ); - array_push(self::$_cronTasks, $cronActionName); - } - } - - public static function unregisterCronTask($cronActionName){ - wp_clear_scheduled_hook($cronActionName); - if(! empty(self::$_cronTasks)){ - if(isset(self::$_cronTasks[$cronActionName])){ - unset(self::$_cronTasks[$cronActionName]); - } - } - } - - public static function unregisterCronTasks(){ - if(! empty(self::$_cronTasks)){ - foreach (self::$_cronTasks as $task) { - wp_clear_scheduled_hook($task); - } - self::$_cronTasks = array(); - } - } - - /** - * Check to see whether or not cron is enabled in WordPress - * @return bool - */ - public static function canRegisterCronTask(){ return ((defined('DISABLE_WP_CRON') && 'DISABLE_WP_CRON') ? false : true); } - - /** - * Register a task - * @param string $callback The callback to register - * @param string $wpActionName Optional. If provided it must be a valid action name to hook the $callback to. If omitted, then the $callback will just be executed. - * @return void - */ - public static function registerTask($callback, $wpActionName = '') { - if(! empty($wpActionName)){ - add_action($wpActionName, $callback); - } - else { - if(is_callable($callback)){ - call_user_func($callback); - } - } - } -} \ No newline at end of file diff --git a/wp-content/plugins/wp-security-scan/res/inc/WsdSecurity.php b/wp-content/plugins/wp-security-scan/res/inc/WsdSecurity.php deleted file mode 100644 index b314dbd8..00000000 --- a/wp-content/plugins/wp-security-scan/res/inc/WsdSecurity.php +++ /dev/null @@ -1,716 +0,0 @@ -Displaying your WordPress version on frontend and in the backend\'s footer to all visitors - and users of your website is a security risk because if a hacker knows which version of WordPress a website is running, it can make it easier for him to target a known WordPress security issue.

',WpsSettings::TEXT_DOMAIN), - sprintf(__('

This plugin can automatically hide your WordPress version from frontend, backend and rss feeds if the option "%s" is checked on the plugin\'s settings page.

',WpsSettings::TEXT_DOMAIN), - 'Hide WordPress version for all users but administrators') - ); - return; - } - - //@@ back-end - if(is_admin()) - { - if(! WsdUtil::isAdministrator()){ - function __hideFooterVersion(){ return ' ';} - add_filter( 'update_footer', '__hideFooterVersion',800); - } - self::$isVersionHidden = true; - // version hidden - self::alert($actionName, $alertType, WpsSettings::ALERT_INFO, - __('WordPress version is only displayed to administrator users',WpsSettings::TEXT_DOMAIN), - __('

Displaying your WordPress version on frontend and in the backend\'s footer to all visitors - and users of your website is a security risk because if a hacker knows which version of WordPress a website is running, it can make it easier for him to target a known WordPress security issue.

',WpsSettings::TEXT_DOMAIN) - ); - } - //@@ front-end - else { - if(WsdUtil::isAdministrator()){ - return; - } - global $wp_db_version, $manifest_version, $tinymce_version; - - // random values - $v = intval( rand(0, 9999) ); - $d = intval( rand(9999, 99999) ); - $m = intval( rand(99999, 999999) ); - $t = intval( rand(999999, 9999999) ); - - if ( function_exists('the_generator') ) - { - // eliminate version for wordpress >= 2.4 - remove_filter( 'wp_head', 'wp_generator' ); - $actions = array( 'rss2_head', 'commentsrss2_head', 'rss_head', 'rdf_header', 'atom_head', 'comments_atom_head', 'opml_head', 'app_head' ); - foreach ( $actions as $action ) { - remove_action( $action, 'the_generator' ); - } - // for vars - $wp_db_version = $d; - $manifest_version = $m; - $tinymce_version = $t; - } - self::$isVersionHidden = true; - - // version hidden - self::alert($actionName, $alertType, WpsSettings::ALERT_INFO, - __('WordPress version is only displayed to administrator users',WpsSettings::TEXT_DOMAIN), - __('

Displaying your WordPress version on frontend and in the backend\'s footer to all visitors - and users of your website is a security risk because if a hacker knows which version of WordPress a website is running, it can make it easier for him to target a known WordPress security issue.

',WpsSettings::TEXT_DOMAIN) - ); - } - } - - /** Remove various meta tags generators from the blog's head tag for non-administrators */ - public static function fix_removeWpMetaGeneratorsFrontend() - { - global $wpsPluginAlertsArray; - $actionName = $wpsPluginAlertsArray['fix_wp_generators_frontend']['name']; - $alertType = $wpsPluginAlertsArray['fix_wp_generators_frontend']['type']; - - /* This check is important so this function will run only if the user enables it. */ - if(! self::isSettingEnabled(__FUNCTION__)){ - self::alert($actionName, $alertType, WpsSettings::ALERT_CRITICAL, - __('WordPress meta tags are displayed on frontend to all users',WpsSettings::TEXT_DOMAIN), - __('

By default, WordPress creates a few meta tags, among which is the currently installed version, that give a hacker the knowledge about your WordPress installation. At the moment, these meta tags are available for anyone to see, which is a potentially security risk.

',WpsSettings::TEXT_DOMAIN), - sprintf(__('

This plugin can automatically hide your WordPress\'s default meta tags if the option "%s" is checked on the plugin\'s settings page.

',WpsSettings::TEXT_DOMAIN), 'Remove various meta tags generators from the blog\'s head tag for non-administrators') - ); - return; - } - - if (!is_admin()) - { - if(!WsdUtil::isAdministrator()){ - //@@ remove various meta tags generators from blog's head tag - function acx_filter_generator($gen, $type) - { - switch ( $type ) { - case 'html': - $gen = ''; - break; - case 'xhtml': - $gen = ''; - break; - case 'atom': - $gen = 'WordPress'; - break; - case 'rss2': - $gen = 'http://wordpress.org/?v='; - break; - case 'rdf': - $gen = ''; - break; - case 'comment': - $gen = ''; - break; - } - return $gen; - } - foreach ( array( 'html', 'xhtml', 'atom', 'rss2', 'rdf', 'comment' ) as $type ) { - add_filter( "get_the_generator_".$type, 'acx_filter_generator', 10, 2 ); - } - } - } - // version hidden - self::alert($actionName, $alertType, WpsSettings::ALERT_INFO, - __('WordPress meta tags are only displayed on frontend to administrator users',WpsSettings::TEXT_DOMAIN), - __('

By default, WordPress creates a few meta tags, among which is the currently installed version, that give a hacker the knowledge about your WordPress installation. - At the moment, all WordPress\'s defaults meta tags are hidden for all users but administrators.

',WpsSettings::TEXT_DOMAIN) - ); - } - - /** Remove Really Simple Discovery meta tags from front-end */ - public static function fix_removeReallySimpleDiscovery() - { - global $wpsPluginAlertsArray; - $actionName = $wpsPluginAlertsArray['fix_wp_rsd_frontend']['name']; - $alertType = $wpsPluginAlertsArray['fix_wp_rsd_frontend']['type']; - - /* This check is important so this function will run only if the user enables it. */ - if(! self::isSettingEnabled(__FUNCTION__)){ - self::alert($actionName, $alertType, WpsSettings::ALERT_INFO, - __('WordPress Really Simple Discovery tag is displayed on frontend to all users',WpsSettings::TEXT_DOMAIN), - sprintf(__('

By default, WordPress creates the rsd meta tag to allow bloggers to consume services like Flickr using the XML-RPC protocol. - If you don\'t use such services it is recommended to hide this meta tag.

',WpsSettings::TEXT_DOMAIN), - 'http://en.wikipedia.org/wiki/XML-RPC', '_blank'), - sprintf(__('

This plugin can automatically hide the rsd meta tag if the option "%s" is checked on the plugin\'s settings page.

',WpsSettings::TEXT_DOMAIN), 'Remove Really Simple Discovery meta tags from front-end') - ); - return; - } - - if (!is_admin()) { - if(!WsdUtil::isAdministrator() && function_exists('rsd_link')) { - remove_action('wp_head', 'rsd_link'); - } - } - self::alert($actionName, $alertType, WpsSettings::ALERT_INFO, - __('WordPress Really Simple Discovery tag is only displayed on frontend to administrator users.',WpsSettings::TEXT_DOMAIN), - sprintf(__('

By default, WordPress creates the rsd meta tag to allow bloggers to consume services like Flickr using the XML-RPC protocol. - If you don\'t use such services it is recommended to hide this meta tag.

',WpsSettings::TEXT_DOMAIN), - 'http://en.wikipedia.org/wiki/XML-RPC', '_blank') - ); - } - - /** Remove Windows Live Writer meta tags from front-end */ - public static function fix_removeWindowsLiveWriter() - { - global $wpsPluginAlertsArray; - $actionName = $wpsPluginAlertsArray['fix_wp_wlw_frontend']['name']; - $alertType = $wpsPluginAlertsArray['fix_wp_wlw_frontend']['type']; - - /* This check is important so this function will run only if the user enables it. */ - if(! self::isSettingEnabled(__FUNCTION__)){ - self::alert($actionName, $alertType, WpsSettings::ALERT_MEDIUM, - __('WordPress Windows Live Writer tag is displayed on frontend for all users',WpsSettings::TEXT_DOMAIN), - sprintf(__('

By default, WordPress creates the wlw meta tag to allow bloggers to publish their articles using the "%s" application. - It is recommended to hide this meta tag from all visitors. If the option "%s" is checked on the plugin\'s settings page, this meta tag - will still be available for administrator users to use the "%s" application to publish their blog posts.

',WpsSettings::TEXT_DOMAIN), - 'Windows Live Writer', 'Remove Windows Live Writer meta tags from front-end', 'Windows Live Writer'), - sprintf(__('

This plugin can automatically hide the wlw meta tag if the option "%s" is checked on the plugin\'s settings page.

',WpsSettings::TEXT_DOMAIN), 'Remove Windows Live Writer meta tags from front-end"') - ); - return; - } - - if (!is_admin() && function_exists('wlwmanifest_link')) { - if(!WsdUtil::isAdministrator()) { - remove_action('wp_head', 'wlwmanifest_link'); - } - } - self::alert($actionName, $alertType, WpsSettings::ALERT_INFO, - __('WordPress Windows Live Writer tag is only displayed on frontend for administrator users',WpsSettings::TEXT_DOMAIN), - sprintf(__('

By default, WordPress creates the wlw meta tag to allow bloggers to publish their articles using the "%s" application. - It is recommended to hide this meta tag from all visitors. If the option "%s" is checked on the plugin\'s settings page, this meta tag - will still be available for administrator users to use the "%s" application to publish their blog posts.

',WpsSettings::TEXT_DOMAIN), - 'Windows Live Writer', 'Remove Windows Live Writer meta tags from front-end', 'Windows Live Writer') - ); - } - - /** Disable error reporting (php + db) for all but administrators */ - public static function fix_disableErrorReporting() - { - global $wpsPluginAlertsArray; - $actionName = $wpsPluginAlertsArray['fix_wp_error_reporting']['name']; - $alertType = $wpsPluginAlertsArray['fix_wp_error_reporting']['type']; - - /* This check is important so this function will run only if the user enables it. */ - if(! self::isSettingEnabled(__FUNCTION__)){ - self::alert($actionName, $alertType, WpsSettings::ALERT_CRITICAL, - __('The check for PHP and database error reporting is disabled',WpsSettings::TEXT_DOMAIN), - sprintf(__('

By default, WordPress hides database errors, but there are times when a plugin might enable them thus it is very important to have this type of errors turned off - so if there is an error during a connection to the database the user will not get access to the error message generated during that request.

-

As regarding the PHP errors, with the display_error PHP configuration directive enabled, untrusted sources can see detailed web application environment - error messages which include sensitive information that can be used to craft further attacks.

-

Attackers will do anything to collect information in order to design their attack in a more sophisticated way to eventually hack your website or web application, and causing - errors to display is a common starting point. Website errors can always occur, but they should be suppressed from being displayed back to the public.

-

Therefore we highly recommend you to have the "%s" option checked on the plugin\'s settings page to ensure PHP and - database errors will be hidden from all users. For more information, please check the following article.

',WpsSettings::TEXT_DOMAIN), - 'Disable error reporting (php + db) for all but administrators', 'http://www.acunetix.com/blog/web-security-zone/articles/php-security-directive-your-website-is-showing-php-errors/', '_blank'), - sprintf(__('

This plugin can do this automatically if the option "%s" is checked on the plugin\'s settings page.

',WpsSettings::TEXT_DOMAIN), - 'Disable error reporting (php + db) for all but administrators') - ); - return; - } - if(! WsdUtil::isAdministrator()) - { - @error_reporting(0); - @ini_set('display_errors','Off'); - @ini_set('display_startup_errors', 0); - global $wpdb; - $wpdb->hide_errors(); - $wpdb->suppress_errors(); - } - self::alert($actionName, $alertType, WpsSettings::ALERT_INFO, - __('Error reporting, PHP and database, is enabled only for administrator users',WpsSettings::TEXT_DOMAIN), - sprintf(__('

By default, WordPress hides database errors, but there are times when a plugin might enable them thus it is very important to have this type of errors turned off - so if there is an error during a connection to the database the user will not get access to the error message generated during that request.

-

As regarding the PHP errors, with the display_error PHP configuration directive enabled, untrusted sources can see detailed web application environment - error messages which include sensitive information that can be used to craft further attacks.

-

Attackers will do anything to collect information in order to design their attack in a more sophisticated way to eventually hack your website or web application, and causing - errors to display is a common starting point. Website errors can always occur, but they should be suppressed from being displayed back to the public.

-

Therefore we highly recommend you to have the "%s" option checked on the plugin\'s settings page to ensure PHP and - database errors will be hidden from all users. For more information, please check the following article.

',WpsSettings::TEXT_DOMAIN), - 'Disable error reporting (php + db) for all but administrators', 'http://www.acunetix.com/blog/web-security-zone/articles/php-security-directive-your-website-is-showing-php-errors/', '_blank') - ); - } - - /** Remove core update notifications from back-end for all but administrators */ - public static function fix_removeCoreUpdateNotification() - { - global $wpsPluginAlertsArray; - $actionName = $wpsPluginAlertsArray['fix_wp_core_update_notif']['name']; - $alertType = $wpsPluginAlertsArray['fix_wp_core_update_notif']['type']; - - /* This check is important so this function will run only if the user enables it. */ - if(! self::isSettingEnabled(__FUNCTION__)){ - self::alert($actionName, $alertType, WpsSettings::ALERT_CRITICAL, - __('Core update notifications are displayed to all users',WpsSettings::TEXT_DOMAIN), - __('

These notifications are displayed at the top of the screen by the WordPress platform whenever the website was updated or needs an update.

-

These notifications should only be viewed by the website\'s administrators and not visible to any other users registered with that website.

',WpsSettings::TEXT_DOMAIN), - sprintf(__('

This plugin can automatically hide these notifications if the option "%s" is checked on the plugin\'s settings page.

',WpsSettings::TEXT_DOMAIN), 'Remove core update notifications from back-end for all but administrators') - ); - return; - } - - if (!WsdUtil::isAdministrator()) - { - add_action( 'admin_init', create_function( '$a', "remove_action( 'admin_notices', 'maintenance_nag' );" ) ); - add_action( 'admin_init', create_function( '$a', "remove_action( 'admin_notices', 'update_nag', 3 );" ) ); - add_action( 'admin_init', create_function( '$a', "remove_action( 'admin_init', '_maybe_update_core' );" ) ); - add_action( 'init', create_function( '$a', "remove_action( 'init', 'wp_version_check' );" ) ); - add_filter( 'pre_option_update_core', create_function( '$a', "return null;" ) ); - remove_action( 'wp_version_check', 'wp_version_check' ); - remove_action( 'admin_init', '_maybe_update_core' ); - add_filter( 'pre_transient_update_core', create_function( '$a', "return null;" ) ); - add_filter( 'pre_site_transient_update_core', create_function( '$a', "return null;" ) ); - } - self::alert($actionName, $alertType, WpsSettings::ALERT_INFO, - __('Core update notifications are only displayed to administrator users.',WpsSettings::TEXT_DOMAIN), - __('

These notifications are displayed at the top of the screen by the WordPress platform whenever the website was updated or needs an update.

-

Currently, these notifications are only displayed to administrator users.

',WpsSettings::TEXT_DOMAIN) - ); - } - - /** Remove plug-ins update notifications from back-end */ - public static function fix_removePluginUpdateNotifications() - { - global $wpsPluginAlertsArray; - $actionName = $wpsPluginAlertsArray['fix_wp_plugins_update_notif']['name']; - $alertType = $wpsPluginAlertsArray['fix_wp_plugins_update_notif']['type']; - - /* This check is important so this function will run only if the user enables it. */ - if(! self::isSettingEnabled(__FUNCTION__)){ - self::alert($actionName, $alertType, WpsSettings::ALERT_MEDIUM, - __('Plugins update notifications are displayed to all users',WpsSettings::TEXT_DOMAIN), - __('

These notifications are displayed at the top of the screen by the WordPress platform whenever the blog administrator - needs to be informed about an available update for a plugin.

-

These notifications should only be viewed by the website\'s administrators and not visible to any other users registered with that website.

',WpsSettings::TEXT_DOMAIN), - sprintf(__('

This plugin can automatically hide these notifications if the option "%s" is checked on the plugin\'s settings page.

',WpsSettings::TEXT_DOMAIN), 'Remove plug-ins update notifications from back-end') - ); - return; - } - - if (!WsdUtil::isAdministrator()) - { - add_action( 'admin_init', create_function( '$a', "remove_action( 'admin_init', 'wp_plugin_update_rows' );" ), 2 ); - add_action( 'admin_init', create_function( '$a', "remove_action( 'admin_init', '_maybe_update_plugins' );" ), 2 ); - add_action( 'admin_menu', create_function( '$a', "remove_action( 'load-plugins.php', 'wp_update_plugins' );" ) ); - add_action( 'admin_init', create_function( '$a', "remove_action( 'admin_init', 'wp_update_plugins' );" ), 2 ); - add_action( 'init', create_function( '$a', "remove_action( 'init', 'wp_update_plugins' );" ), 2 ); - add_filter( 'pre_option_update_plugins', create_function( '$a', "return null;" ) ); - remove_action( 'load-plugins.php', 'wp_update_plugins' ); - remove_action( 'load-update.php', 'wp_update_plugins' ); - remove_action( 'admin_init', '_maybe_update_plugins' ); - remove_action( 'wp_update_plugins', 'wp_update_plugins' ); - remove_action( 'load-update-core.php', 'wp_update_plugins' ); - add_filter( 'pre_transient_update_plugins', create_function( '$a', "return null;" ) ); - } - self::alert($actionName, $alertType, WpsSettings::ALERT_INFO, - __('Plugins update notifications are only displayed to administrator users',WpsSettings::TEXT_DOMAIN), - __('

Currently, these notifications are only displayed to administrator users.

',WpsSettings::TEXT_DOMAIN) - ); - } - - /** Remove themes update notifications from back-end */ - public static function fix_removeThemeUpdateNotifications() - { - global $wpsPluginAlertsArray; - $actionName = $wpsPluginAlertsArray['fix_wp_themes_update_notif']['name']; - $alertType = $wpsPluginAlertsArray['fix_wp_themes_update_notif']['type']; - - /* This check is important so this function will run only if the user enables it. */ - if(! self::isSettingEnabled(__FUNCTION__)){ - self::alert($actionName, $alertType, WpsSettings::ALERT_INFO, - __('Themes update notifications are displayed to all users.',WpsSettings::TEXT_DOMAIN), - __('

These notifications are displayed at the top of the screen by the WordPress platform whenever the blog administrator - needs to be informed about an available update for a theme.

-

These notifications should only be viewed by the website\'s administrators and not visible to any other users registered with that website.

',WpsSettings::TEXT_DOMAIN), - sprintf(__('

This plugin can automatically hide these notifications if the option "%s" is checked on the plugin\'s settings page.

',WpsSettings::TEXT_DOMAIN), 'Remove themes update notifications from back-end') - ); - return; - } - - if (!WsdUtil::isAdministrator()) - { - remove_action( 'load-themes.php', 'wp_update_themes' ); - remove_action( 'load-update.php', 'wp_update_themes' ); - remove_action( 'admin_init', '_maybe_update_themes' ); - remove_action( 'wp_update_themes', 'wp_update_themes' ); - remove_action( 'load-update-core.php', 'wp_update_themes' ); - add_filter( 'pre_transient_update_themes', create_function( '$a', "return null;" ) ); - } - self::alert($actionName, $alertType, WpsSettings::ALERT_INFO, - __('Themes update notifications are only displayed to administrator users',WpsSettings::TEXT_DOMAIN), - __('

Currently, these notifications are only displayed to administrator users.

',WpsSettings::TEXT_DOMAIN) - ); - } - - /** Remove login error notifications from front-end */ - public static function fix_removeLoginErrorNotificationsFrontEnd() - { - global $wpsPluginAlertsArray; - $actionName = $wpsPluginAlertsArray['fix_wp_login_errors']['name']; - $alertType = $wpsPluginAlertsArray['fix_wp_login_errors']['type']; - - /* This check is important so this function will run only if the user enables it. */ - if(! self::isSettingEnabled(__FUNCTION__)){ - self::alert($actionName, $alertType, WpsSettings::ALERT_MEDIUM, - __('WordPress login errors are displayed.',WpsSettings::TEXT_DOMAIN), - __('

Every time a failed login is encountered, the WordPress platform generates an error message that is displayed to the user. - This is a potential security risk because it let\'s the user know of his mistake (be it a wrong user name or password) thus making your - WordPress website more vulnerable to attacks.

-

We strongly recommend you to hide these login error messages from all users to ensure a better security of your blog.

',WpsSettings::TEXT_DOMAIN), - sprintf(__('

This plugin can automatically hide these notifications if the option "%s" is checked on the plugin\'s settings page.

',WpsSettings::TEXT_DOMAIN), 'Remove login error notifications from front-end') - ); - return; - } - $str = ''; - add_action('login_head', create_function('$a', "echo '{$str}';")); - add_filter('login_errors', create_function('$a', "return null;")); - self::alert($actionName, $alertType, WpsSettings::ALERT_INFO, - __('WordPress login errors are not displayed.',WpsSettings::TEXT_DOMAIN), - __('

Currently, these errors are hidden to all users.

',WpsSettings::TEXT_DOMAIN) - ); - } - - /** Hide admin notifications for non admins */ - public static function fix_hideAdminNotifications() - { - global $wpsPluginAlertsArray; - $actionName = $wpsPluginAlertsArray['fix_wp_admin_notices']['name']; - $alertType = $wpsPluginAlertsArray['fix_wp_admin_notices']['type']; - - /* This check is important so this function will run only if the user enables it. */ - if(! self::isSettingEnabled(__FUNCTION__)){ - self::alert($actionName, $alertType, WpsSettings::ALERT_MEDIUM, - __('WordPress admin notifications are displayed to all users.',WpsSettings::TEXT_DOMAIN), - __('

These notifications are displayed at the top of the screen by the WordPress platform whenever the blog administrator - needs to be informed about an event that has occurred inside WordPress, it could be about an available update for the - WordPress platform, a plugin or a theme that was updated or needs an update or to be configured, etc.

-

These notifications should only be viewed by the website\'s administrators and not visible to any other users registered with that website.

',WpsSettings::TEXT_DOMAIN), - sprintf(__('

This plugin can automatically hide these notifications if the option "%s" is checked on the plugin\'s settings page.

',WpsSettings::TEXT_DOMAIN), 'Hide admin notifications for non admins') - ); - return; - } - - if (!WsdUtil::isAdministrator()) - { - add_action('init', create_function('$a', "remove_action('init', 'wp_version_check');"), 2); - add_filter('pre_option_update_core', create_function('$a', "return null;")); - } - self::alert($actionName, $alertType, WpsSettings::ALERT_INFO, - __('WordPress admin notifications are only displayed to administrator users.',WpsSettings::TEXT_DOMAIN), - __('

These notifications are displayed at the top of the screen by the WordPress platform whenever the blog administrator - needs to be informed about an event that has occurred inside WordPress, it could be about an available update for the - WordPress platform, a plugin or a theme that was updated or needs an update or to be configured, etc.

-

Currently, these notifications are displayed only to administrator users.

',WpsSettings::TEXT_DOMAIN)); - } - - /** Try to create the index.php file in the wp-content, wp-content/plugins, wp-content/themes and wp-content/uploads directories to prevent directory listing */ - public static function fix_preventDirectoryListing() - { - global $wpsPluginAlertsArray; - - $actionName = $wpsPluginAlertsArray['fix_wp_dir_listing']['name']; - $alertType = $wpsPluginAlertsArray['fix_wp_dir_listing']['type']; - /* This check is important so this function will run only if the user enables it. */ - if(! self::isSettingEnabled(__FUNCTION__)){ - self::alert($actionName, $alertType, WpsSettings::ALERT_MEDIUM, - __('Directory listing check is disabled. This option should be enabled.',WpsSettings::TEXT_DOMAIN), - __('

A directory listing provides an attacker with the complete index of all the resources located inside of the directory. - The specific risks and consequences vary depending on which files are listed and accessible. - Therefore, it is important to protect your directories by having an empty index.php or index.htm file inside them.

',WpsSettings::TEXT_DOMAIN), - sprintf(__('

This plugin can automatically create an empty index.php file in the following directories: wp-content, wp-content/plugins, wp-content/themes and wp-content/uploads if - the option "%s" is checked on the plugin\'s settings page.

',WpsSettings::TEXT_DOMAIN), - 'Try to create the index.php file in the wp-content, wp-content/plugins, wp-content/themes and wp-content/uploads directories to prevent directory listing') - ); - return; - } - else { - self::alert($actionName, $alertType, WpsSettings::ALERT_INFO, - __('Directory listing check is enabled.',WpsSettings::TEXT_DOMAIN), - __('

A directory listing provides an attacker with the complete index of all the resources located inside of the directory. - The specific risks and consequences vary depending on which files are listed and accessible. - Therefore, it is important to protect your directories by having an empty index.php or index.htm file inside them.

',WpsSettings::TEXT_DOMAIN) - ); - } - - $data = ''; - $contentDir = trailingslashit(WP_CONTENT_DIR); - $pluginsDir = $contentDir.'plugins'; - $themesDir = $contentDir.'themes'; - $uploadsDir = $contentDir.'uploads'; - - $actionName = $wpsPluginAlertsArray['fix_wp_index_content']['name']; - $alertType = $wpsPluginAlertsArray['fix_wp_index_content']['type']; - $file = $contentDir.'/index.php'; - if(is_dir($contentDir)){ - if(is_file($file)){ - self::alert($actionName, $alertType, WpsSettings::ALERT_INFO, - sprintf(__('"%s" directory is secure from directory listing.',WpsSettings::TEXT_DOMAIN),'/wp-content'), - __('

A directory listing provides an attacker with the complete index of all the resources located inside of the directory. - The specific risks and consequences vary depending on which files are listed and accessible. - Therefore, it is important to protect your directories by having an empty index.php or index.htm file inside them.

',WpsSettings::TEXT_DOMAIN) - ); - } - else { - if (is_writable($contentDir)) - { - WsdUtil::writeFile($file,$data); - @chmod($file,'0644'); - self::alert($actionName, $alertType, WpsSettings::ALERT_INFO, - sprintf(__('"%s" directory is secure from directory listing.',WpsSettings::TEXT_DOMAIN),'/wp-content'), - __('

A directory listing provides an attacker with the complete index of all the resources located inside of the directory. - The specific risks and consequences vary depending on which files are listed and accessible. - Therefore, it is important to protect your directories by having an empty index.php or index.htm file inside them.

',WpsSettings::TEXT_DOMAIN) - ); - } - else { - self::alert($actionName, $alertType, WpsSettings::ALERT_MEDIUM, - sprintf(__('"%s" directory is not secure from directory listing.',WpsSettings::TEXT_DOMAIN),'/wp-content'), - __('

A directory listing provides an attacker with the complete index of all the resources located inside of the directory. - The specific risks and consequences vary depending on which files are listed and accessible. - Therefore, it is important to protect your directories by having an empty index.php or index.htm file inside them.

',WpsSettings::TEXT_DOMAIN), - sprintf(__('

This plugin can automatically create an empty index.php file in the following directories: wp-content, wp-content/plugins, wp-content/themes and wp-content/uploads if - the option "%s" is checked on the plugin\'s settings page.

',WpsSettings::TEXT_DOMAIN), - 'Try to create the index.php file in the wp-content, wp-content/plugins, wp-content/themes and wp-content/uploads directories to prevent directory listing') - ); - } - } - } - - $actionName = $wpsPluginAlertsArray['fix_wp_index_plugins']['name']; - $alertType = $wpsPluginAlertsArray['fix_wp_index_plugins']['type']; - $file = $pluginsDir.'/index.php'; - if(is_dir($pluginsDir)){ - if(is_file($file)){ - self::alert($actionName, $alertType, WpsSettings::ALERT_INFO, - sprintf(__('"%s" directory is not secure from directory listing.',WpsSettings::TEXT_DOMAIN),'/wp-content/plugins'), - __('

A directory listing provides an attacker with the complete index of all the resources located inside of the directory. - The specific risks and consequences vary depending on which files are listed and accessible. - Therefore, it is important to protect your directories by having an empty index.php or index.htm file inside them.

',WpsSettings::TEXT_DOMAIN) - ); - } - else { - if (is_writable($pluginsDir)) - { - WsdUtil::writeFile($file,$data); - @chmod($file,'0644'); - self::alert($actionName, $alertType, WpsSettings::ALERT_INFO, - sprintf(__('"%s" directory is not secure from directory listing.',WpsSettings::TEXT_DOMAIN),'/wp-content/plugins'), - __('

A directory listing provides an attacker with the complete index of all the resources located inside of the directory. - The specific risks and consequences vary depending on which files are listed and accessible. - Therefore, it is important to protect your directories by having an empty index.php or index.htm file inside them.

',WpsSettings::TEXT_DOMAIN) - ); - } - else { - self::alert($actionName, $alertType, WpsSettings::ALERT_MEDIUM, - sprintf(__('"%s" directory is not secure from directory listing.',WpsSettings::TEXT_DOMAIN),'/wp-content/plugins'), - __('

A directory listing provides an attacker with the complete index of all the resources located inside of the directory. - The specific risks and consequences vary depending on which files are listed and accessible. - Therefore, it is important to protect your directories by having an empty index.php or index.htm file inside them.

',WpsSettings::TEXT_DOMAIN), - sprintf(__('

This plugin can automatically create an empty index.php file in the following directories: wp-content, wp-content/plugins, wp-content/themes and wp-content/uploads if - the option "%s" is checked on the plugin\'s settings page.

',WpsSettings::TEXT_DOMAIN), - 'Try to create the index.php file in the wp-content, wp-content/plugins, wp-content/themes and wp-content/uploads directories to prevent directory listing') - ); - } - } - } - - $actionName = $wpsPluginAlertsArray['fix_wp_index_themes']['name']; - $alertType = $wpsPluginAlertsArray['fix_wp_index_themes']['type']; - $file = $themesDir.'/index.php'; - if(is_dir($themesDir)){ - if(is_file($file)){ - self::alert($actionName, $alertType, WpsSettings::ALERT_INFO, - sprintf(__('"%s" directory is not secure from directory listing.',WpsSettings::TEXT_DOMAIN),'/wp-content/themes'), - __('

A directory listing provides an attacker with the complete index of all the resources located inside of the directory. - The specific risks and consequences vary depending on which files are listed and accessible. - Therefore, it is important to protect your directories by having an empty index.php or index.htm file inside them.

',WpsSettings::TEXT_DOMAIN) - ); - } - else { - if (is_writable($themesDir)) - { - WsdUtil::writeFile($file,$data); - @chmod($file,'0644'); - self::alert($actionName, $alertType, WpsSettings::ALERT_INFO, - sprintf(__('"%s" directory is not secure from directory listing.',WpsSettings::TEXT_DOMAIN),'/wp-content/themes'), - __('

A directory listing provides an attacker with the complete index of all the resources located inside of the directory. - The specific risks and consequences vary depending on which files are listed and accessible. - Therefore, it is important to protect your directories by having an empty index.php or index.htm file inside them.

',WpsSettings::TEXT_DOMAIN) - ); - } - else { - self::alert($actionName, $alertType, WpsSettings::ALERT_MEDIUM, - sprintf(__('"%s" directory is not secure from directory listing.',WpsSettings::TEXT_DOMAIN),'/wp-content/themes'), - __('

A directory listing provides an attacker with the complete index of all the resources located inside of the directory. - The specific risks and consequences vary depending on which files are listed and accessible. - Therefore, it is important to protect your directories by having an empty index.php or index.htm file inside them.

',WpsSettings::TEXT_DOMAIN), - sprintf(__('

This plugin can automatically create an empty index.php file in the following directories: wp-content, wp-content/plugins, wp-content/themes and wp-content/uploads if - the option "%s" is checked on the plugin\'s settings page.

',WpsSettings::TEXT_DOMAIN), - 'Try to create the index.php file in the wp-content, wp-content/plugins, wp-content/themes and wp-content/uploads directories to prevent directory listing') - ); - } - } - } - - $actionName = $wpsPluginAlertsArray['fix_wp_index_uploads']['name']; - $alertType = $wpsPluginAlertsArray['fix_wp_index_uploads']['type']; - $file = $uploadsDir.'/index.php'; - if(is_dir($uploadsDir)){ - if(is_file($file)){ - self::alert($actionName, $alertType, WpsSettings::ALERT_INFO, - sprintf(__('"%s" directory is not secure from directory listing.',WpsSettings::TEXT_DOMAIN),'/wp-content/uploads'), - __('

A directory listing provides an attacker with the complete index of all the resources located inside of the directory. - The specific risks and consequences vary depending on which files are listed and accessible. - Therefore, it is important to protect your directories by having an empty index.php or index.htm file inside them.

',WpsSettings::TEXT_DOMAIN) - ); - } - else { - if (is_writable($uploadsDir)) - { - WsdUtil::writeFile($file,$data); - @chmod($file,'0644'); - self::alert($actionName, $alertType, WpsSettings::ALERT_INFO, - sprintf(__('"%s" directory is not secure from directory listing.',WpsSettings::TEXT_DOMAIN),'/wp-content/uploads'), - __('

A directory listing provides an attacker with the complete index of all the resources located inside of the directory. - The specific risks and consequences vary depending on which files are listed and accessible. - Therefore, it is important to protect your directories by having an empty index.php or index.htm file inside them.

',WpsSettings::TEXT_DOMAIN) - ); - } - else { - self::alert($actionName, $alertType, WpsSettings::ALERT_MEDIUM, - sprintf(__('"%s" directory is not secure from directory listing.',WpsSettings::TEXT_DOMAIN),'/wp-content/uploads'), - __('

A directory listing provides an attacker with the complete index of all the resources located inside of the directory. - The specific risks and consequences vary depending on which files are listed and accessible. - Therefore, it is important to protect your directories by having an empty index.php or index.htm file inside them.

',WpsSettings::TEXT_DOMAIN), - sprintf(__('

This plugin can automatically create an empty index.php file in the following directories: wp-content, wp-content/plugins, wp-content/themes and wp-content/uploads if - the option "%s" is checked on the plugin\'s settings page.

',WpsSettings::TEXT_DOMAIN), - 'Try to create the index.php file in the wp-content, wp-content/plugins, wp-content/themes and wp-content/uploads directories to prevent directory listing') - ); - } - } - } - } - - /** Remove the version parameter from urls */ - public static function fix_removeWpVersionFromLinks($src = '') - { - global $wpsPluginAlertsArray; - $actionName = $wpsPluginAlertsArray['fix_remove_wp_version_links']['name']; - $alertType = $wpsPluginAlertsArray['fix_remove_wp_version_links']['type']; - - /* This check is important so this function will run only if the user enables it. */ - if(! self::isSettingEnabled(__FUNCTION__)){ - self::alert($actionName, $alertType, WpsSettings::ALERT_CRITICAL, - __('WordPress version is displayed in links for all users',WpsSettings::TEXT_DOMAIN), - __('

By default, WordPress will display the current version in links to javascript scripts or stylesheets. - Therefore, if anyone has access to this information it might be a security risk because if a hacker knows which version of WordPress a website is running, - it can make it easier for him to target a known WordPress security issue.

',WpsSettings::TEXT_DOMAIN), - sprintf(__('

This plugin can automatically hide the WordPress version from links if the option "%s" is checked on the plugin\'s settings page.

',WpsSettings::TEXT_DOMAIN), 'Remove the version parameter from urls') - ); - return; - } - - if (!WsdUtil::isAdministrator()) - { - add_filter('script_loader_src', array('WsdSecurityHelper', '__removeWpVersionFromLinks')); - add_filter('style_loader_src', array('WsdSecurityHelper', '__removeWpVersionFromLinks')); - } - self::alert($actionName, $alertType, WpsSettings::ALERT_INFO, - __('WordPress version displayed in links only for administrator users.',WpsSettings::TEXT_DOMAIN), - __('

By default, WordPress will display the current version in links to javascript scripts or stylesheets. - Therefore, if anyone has access to this information it might be a security risk because if a hacker knows which version of WordPress a website is running, - it can make it easier for him to target a known WordPress security issue.

',WpsSettings::TEXT_DOMAIN) - ); - } - - /** Empty the content of the readme.html file from the root directory */ - public static function fix_emptyReadmeFileFromRoot() - { - global $wpsPluginAlertsArray; - - // if the file is 404 or not readable or empty, there is no need to display the alert - $filePath = trailingslashit(ABSPATH).'readme.html'; - if(! is_file($filePath)){ return; } - if(! is_readable($filePath)) { return; } - $fsize = @filesize($filePath); - if(false !== $fsize && $fsize == 0) { return; } - - $actionName = $wpsPluginAlertsArray['fix_empty_root_readme_file']['name']; - $alertType = $wpsPluginAlertsArray['fix_empty_root_readme_file']['type']; - /* This check is important so this function will run only if the user enables it. */ - if(! self::isSettingEnabled(__FUNCTION__)){ - self::alert($actionName, $alertType, WpsSettings::ALERT_MEDIUM, - sprintf(__('Clearing the content of the "%s" file from the "%s" directory is disabled.',WpsSettings::TEXT_DOMAIN), 'readme.html', 'root'), - __('

A default WordPress installation contains a readme.html file. This file is a simple html file that does not contain executable content that can be exploited by hackers or malicious users. - Still, this file can provide hackers the version of your WordPress installation, therefore it is important to either delete this file or make it inaccessible for your visitors.

',WpsSettings::TEXT_DOMAIN), - sprintf(__('

This plugin can automatically delete its content (assuming the file exists) if the option "%s" is checked on the plugin\'s settings page. - You can also delete this file manually by connecting to your website through an FTP connection.

',WpsSettings::TEXT_DOMAIN), 'Empty the content of the readme.html file from the root directory') - ); - return; - } - else { - // clear the content of the file - $result = file_put_contents($filePath,''); - // failure - if(false === $result){ - // todo - self::alert($actionName, $alertType, WpsSettings::ALERT_MEDIUM, - sprintf(__('The content of the "%s" file from the "%s" directory could not be deleted.',WpsSettings::TEXT_DOMAIN), 'readme.html', 'root'), - __('

A default WordPress installation contains a readme.html file. This file is a simple html file that does not contain executable content that can be exploited by hackers or malicious users. - Still, this file can provide hackers the version of your WordPress installation, therefore it is important to either delete this file or make it inaccessible for your visitors.

',WpsSettings::TEXT_DOMAIN), - __('

We have encountered an error while trying to delete the content of this file, thus you will have to manually delete it or make it inaccessible from your visitors by setting the file permissions to 0440 or lower.

',WpsSettings::TEXT_DOMAIN) - ); - return; - } - self::alert($actionName, $alertType, WpsSettings::ALERT_INFO, - __('The content of the readme.html file from the root directory has been deleted.',WpsSettings::TEXT_DOMAIN), - __('

A default WordPress installation contains a readme.html file. This file is a simple html file that does not contain executable content that can be exploited by hackers or malicious users. - Still, this file can provide hackers the version of your WordPress installation, therefore it is important to either delete this file or make it inaccessible for your visitors.

',WpsSettings::TEXT_DOMAIN) - ); - } - - } - -} - -class WsdSecurityHelper -{ - /** - * @private - * @param $src - * @return mixed - */ - public static function __removeWpVersionFromLinks($src) - { - // Just the URI without the query string. - $src = preg_replace("/\?ver=(.*)/mi", '', $src); - return $src; - } - -} \ No newline at end of file diff --git a/wp-content/plugins/wp-security-scan/res/inc/WsdUtil.php b/wp-content/plugins/wp-security-scan/res/inc/WsdUtil.php deleted file mode 100644 index 784316c4..00000000 --- a/wp-content/plugins/wp-security-scan/res/inc/WsdUtil.php +++ /dev/null @@ -1,663 +0,0 @@ - integer, 'failed' => integer) - */ - static function changeFilePermissions($acxFileList) - { - if (empty($acxFileList)) { - return array(); - } - // chmod doesn't work on windows... :/ - if (self::isWinOs()) { - return array(); - } - - $s = $f = 0; - foreach($acxFileList as $k => $v) - { - $filePath = $v['filePath']; - $sp = $v['suggestedPermissions']; - $sp = (is_string($sp) ? octdec($sp) : $sp); - - // if this is the readme file - $isReadme = false; - if(false !== ($pos = stripos($filePath, 'readme'))){ - $isReadme = true; - } - - //@ include directories too - if (file_exists($filePath)) - { - if (false !== @chmod($filePath, $sp)) { - $s++; - } - else { $f++; } - } - else { - // if no path provided - if(empty($filePath)){ - $f++; - continue; - } - if($isReadme){ // ignore the missing readme.html file - continue; - } - if (false !== @chmod($filePath, $sp)) { - $s++; - } - else { $f++; } - } - } - return array('success' => $s, 'failed' => $f); - } - - static function getWpConfigFilePath() - { - $path = ABSPATH.'wp-config.php'; - if(! is_file($path)){ - // search one level up - $path = realpath('../'.ABSPATH) . '/wp-config.php'; - if(! is_file($path)){ - return ''; - } - } - return $path; - } - - - static function getFilePermissions($filePath) - { - if (!function_exists('fileperms')) { - return '-1'; - } - if (!file_exists($filePath)) { - return '-1'; - } - clearstatcache(); - return substr(sprintf("%o", fileperms($filePath)), -4); - } - - static function normalizePath($path) { - return str_replace('\\', '/', $path); - } - - static function isWinOs(){ - return ((strtoupper(substr(PHP_OS, 0, 3)) === 'WIN') ? true : false); - } - - /** - * Check to see whether or not the current user is an administrator - * @return bool - */ - static function isAdministrator(){ - self::loadPluggable(); - return user_can(wp_get_current_user(),'administrator'); - } - - /** - * Check to see whether or not the specified table exists in the database - * @param $tableName The table to check for existence. It requires the full qualified name of the table - * - which means the prefix must be there as well. - * @return bool - */ - static function tableExists($tableName) - { - global $wpdb; - $result = $wpdb->get_var("SHOW TABLES LIKE '$tableName'"); - return (is_null($result) ? false : true); - } - - /** - * @public - * @uses wp_die() - * - * Backup the database and save the script to the plug-in's backups directory. - * This directory must be writable! - * - * @return string The name of the generated backup file or empty string on failure. - */ - static function backupDatabase() - { - if (!is_writable(WPS_PLUGIN_BACKUPS_DIR)) - { - $s = sprintf(__('The %s directory MUST be writable for this feature to work!',WpsSettings::TEXT_DOMAIN), WPS_PLUGIN_BACKUPS_DIR); - wp_die($s); - } - - $link = mysql_connect(DB_HOST, DB_USER, DB_PASSWORD); - if (!$link) { - wp_die(__('Error: Cannot connect to database.',WpsSettings::TEXT_DOMAIN)); - } - if (!mysql_select_db(DB_NAME,$link)) { - wp_die(__('Error: Could not select the database.',WpsSettings::TEXT_DOMAIN)); - } - - //get all of the tables - $tables = array(); - $result = mysql_query('SHOW TABLES'); - while($row = mysql_fetch_row($result)) - { - if(! empty($row[0])){ - $tables[] = $row[0]; - } - } - - if (empty($tables)) - { - wp_die(__('Could not retrieve the list of tables from the database.',WpsSettings::TEXT_DOMAIN)); - } - - $h = null; - $time = gmdate("m-j-Y-h-i-s", time()); - $rand = self::makeSeed()+rand(12131, 9999999); - $fname = 'bck_'.$time.'_'.$rand.'.sql'; - $filePath = WPS_PLUGIN_BACKUPS_DIR.$fname; - - if(function_exists('fopen') && function_exists('fwrite') && function_exists('fclose')) - { - $h = fopen($filePath,'a+'); - self::__doBackup($filePath, $tables, $h); - fclose($h); - } - else { - if(function_exists('file_put_contents')){ - self::__doBackup($filePath, $tables, $h); - } - } - if(! is_file($filePath)){ - return ''; - } - $fs = @filesize($filePath); - return (($fs > 0) ? $fname : ''); - } - - /** - * @private - */ - private static function __doBackup($filePath, array $tables = array(), $h = null) - { - $data = 'CREATE DATABASE IF NOT EXISTS '.DB_NAME.';'.PHP_EOL; - $data .= 'USE '.DB_NAME.';'.PHP_EOL; - self::writeFile($filePath, $data, $h); - - //cycle through - foreach($tables as $table) - { - $result = mysql_query('SELECT * FROM '.$table); - $num_fields = mysql_num_fields($result); - - $data = 'DROP TABLE IF EXISTS '.$table.';'; - $row2 = mysql_fetch_row(mysql_query('SHOW CREATE TABLE '.$table)); - $data .= $row2[1].';'.PHP_EOL; - self::writeFile($filePath, $data, $h); - - for ($i = 0; $i < $num_fields; $i++) - { - while($row = mysql_fetch_row($result)) - { - $data = 'INSERT INTO '.$table.' VALUES('; - for($j=0; $j<$num_fields; $j++) - { - $row[$j] = addslashes($row[$j]); - $row[$j] = @preg_replace("/\n(\s*\n)+/",PHP_EOL,$row[$j]); - if (isset($row[$j])) { $data .= '"'.$row[$j].'"' ; } else { $data .= '""'; } - if ($j<($num_fields-1)) { $data .= ','; } - } - $data .= ");".PHP_EOL; - self::writeFile($filePath, $data, $h); - } - } //#! end for - } //#! end foreach - } - - /** - * @public - * Retrieve the list of all available backup files from the backups directory - * @return array - */ - static function getAvailableBackupFiles() - { - $files = glob(WPS_PLUGIN_BACKUPS_DIR.'*.sql'); - if (empty($files)) { return array();} - return array_map('basename', $files/*, array('.sql')*/); - } - - /** - * @public - * Create a number - * @return double - */ - static function makeSeed() - { - list($usec, $sec) = explode(' ', microtime()); - return (float)$sec + ((float)$usec * 100000); - } - - /** - * @public - * @global object $wpdb - * Get the list of tables to modify - * @return array - */ - static function getTablesToAlter() - { - global $wpdb; - return $wpdb->get_results("SHOW TABLES LIKE '".$GLOBALS['table_prefix']."%'", ARRAY_N); - } - - /** - * @public - * @global object $wpdb - * Rename tables from database - * @param array the list of tables to rename - * @param string $currentPrefix the current prefix in use - * @param string $newPrefix the new prefix to use - * @return array - */ - static function renameTables($tables, $currentPrefix, $newPrefix) - { - global $wpdb; - $changedTables = array(); - foreach ($tables as $k=>$table){ - $tableOldName = $table[0]; - // Try to rename the table - $tableNewName = substr_replace($tableOldName, $newPrefix, 0, strlen($currentPrefix)); - // Try to rename the table - $wpdb->query("RENAME TABLE `{$tableOldName}` TO `{$tableNewName}`"); - array_push($changedTables, $tableNewName); - } - return $changedTables; - } - - /** - * @public - * @global object $wpdb - * Rename some fields from options & usermeta tables in order to reflect the prefix change - * @param string $oldPrefix the existent db prefix - * @param string $newPrefix the new prefix to use - * @return string - */ - static function renameDbFields($oldPrefix,$newPrefix) - { - global $wpdb; - $str = ''; - if (false === $wpdb->query("UPDATE {$newPrefix}options SET option_name='{$newPrefix}user_roles' WHERE option_name='{$oldPrefix}user_roles';")) { - $str .= '
'.sprintf(__('Changing value: %suser_roles in table %soptions: Failed',WpsSettings::TEXT_DOMAIN),$newPrefix, $newPrefix); - } - $query = 'UPDATE '.$newPrefix.'usermeta - SET meta_key = CONCAT(replace(left(meta_key, ' . strlen($oldPrefix) . "), '{$oldPrefix}', '{$newPrefix}'), SUBSTR(meta_key, " . (strlen($oldPrefix) + 1) . ")) - WHERE - meta_key IN ('{$oldPrefix}autosave_draft_ids', '{$oldPrefix}capabilities', '{$oldPrefix}metaboxorder_post', '{$oldPrefix}user_level', '{$oldPrefix}usersettings', - '{$oldPrefix}usersettingstime', '{$oldPrefix}user-settings', '{$oldPrefix}user-settings-time', '{$oldPrefix}dashboard_quick_press_last_post_id')"; - - if (false === $wpdb->query($query)) { - $str .= '
'.sprintf(__('Changing values in table %susermeta: Failed',WpsSettings::TEXT_DOMAIN), $newPrefix); - } - if (!empty($str)) { - $str = __('Changing database prefix',WpsSettings::TEXT_DOMAIN).': '.$str; - } - return $str; - } - - /** - * @public - * Update the wp-config file to reflect the table prefix change. - * The wp file must be writable for this operation to work! - * - * @param string $wsd_wpConfigFile The path to the wp-config file - * @param string $newPrefix The new prefix to use instead of the old one - * @return int the number of bytes written to te file or -1 on error - */ - static function updateWpConfigTablePrefix($wsd_wpConfigFile, $newPrefix) - { - // If file is not writable... - if (!is_writable($wsd_wpConfigFile)){ - return -1; - } - - // We need the 'file' function... - if (!function_exists('file')) { - return -1; - } - - // Try to update the wp-config file - $lines = file($wsd_wpConfigFile); - $fcontent = ''; - $result = -1; - foreach($lines as $line) - { - $line = ltrim($line); - if (!empty($line)){ - if (strpos($line, '$table_prefix') !== false){ - $line = preg_replace("/=(.*)\;/", "= '".$newPrefix."';", $line); - } - } - $fcontent .= $line; - } - if (!empty($fcontent)) - { - // Save wp-config file - $result = self::writeFile($wsd_wpConfigFile, $fcontent); - } - return $result; - } - - - private static $_pluginID = 'acx_plugin_dashboard_widget'; - - /** - * @public - * @static - * @const BLOG_FEED - * Retrieve and display a list of links for an existing RSS feed, limiting the selection to the 5 most recent items. - * @return void - */ - static function displayDashboardWidget() - { - //@ flag - $run = false; - - //@ check cache - $optData = WpsOption::getOption(WpsSettings::FEED_DATA_OPTION_NAME); - if (! empty($optData)) - { - if (is_object($optData)) - { - $lastUpdateTime = @$optData->expires; - // invalid cache - if (empty($lastUpdateTime)) { $run = true; } - else - { - $nextUpdateTime = $lastUpdateTime+(24*60*60); - if ($nextUpdateTime >= $lastUpdateTime) - { - $data = @$optData->data; - if (empty($data)) { $run = true; } - else { - // still a valid cache - echo $data; - return; - } - } - else { $run = true; } - } - } - else { $run = true; } - } - else { $run = true; } - - if (!$run) { return; } - - $rss = fetch_feed(WpsSettings::BLOG_FEED); - - $out = ''; - if (is_wp_error( $rss ) ) - { - $out = '
  • '.__('An error has occurred while trying to load the rss feed.',WpsSettings::TEXT_DOMAIN).'
  • '; - echo $out; - return; - } - else - { - // Limit to 5 entries. - $maxitems = $rss->get_item_quantity(5); - - // Build an array of all the items, - $rss_items = $rss->get_items(0, $maxitems); - - $out .= ''; - $out .= '
    '; - $out .= '

    '; - $out .= ''.__('Follow us on RSS',WpsSettings::TEXT_DOMAIN).''; - $out .= '

    '; - $out .= '
    '; - } - // Update cache - $obj = new stdClass(); - $obj->expires = time(); - $obj->data = $out; - WpsOption::updateOption(WpsSettings::FEED_DATA_OPTION_NAME, $obj); - echo $out; - } - - /** - * @public - * @static - * Add the rss widget to dashboard - * @return void - */ - static function addDashboardWidget() - { - $rssWidgetData = WpsOption::getOption('WSD-RSS-WGT-DISPLAY'); - if(($rssWidgetData == 'yes')) - { - if(wpsIsMultisite()){ - global $wpdb; - $old_blog = $wpdb->blogid; - // Get all blog ids - $blogIds = $wpdb->get_col("SELECT blog_id FROM $wpdb->blogs"); - foreach ($blogIds as $blog_id) { - switch_to_blog($blog_id); - wp_add_dashboard_widget('acx_plugin_dashboard_widget', __('Acunetix news and updates',WpsSettings::TEXT_DOMAIN), array('WsdUtil','displayDashboardWidget')); - } - switch_to_blog($old_blog); - wp_add_dashboard_widget('acx_plugin_dashboard_widget', __('Acunetix news and updates',WpsSettings::TEXT_DOMAIN), array('WsdUtil','displayDashboardWidget')); - } - else { wp_add_dashboard_widget('acx_plugin_dashboard_widget', __('Acunetix news and updates',WpsSettings::TEXT_DOMAIN), array('WsdUtil','displayDashboardWidget')); } - } - } - - /** - * This method allows the scanner to ignore a default WP file if not found - * @param string $crtFullFilePath - * @return bool - */ - static function canIgnoreScanPath($crtFullFilePath) - { - // search in themes - $themes = WpsSettings::$ignoreThemes; - foreach($themes as $themeName){ - if(false !== ($pos = stripos($crtFullFilePath, $themeName))){ - return true; - } - } - // search in plugins - $plugins = WpsSettings::$ignorePlugins; - foreach($plugins as $pluginPath){ - if(false !== ($pos = stripos($crtFullFilePath, $pluginPath))){ - return true; - } - } - return false; - } - - static function loadPluggable(){ @require_once(ABSPATH.'wp-includes/pluggable.php'); } - - // utility method to delete backup files. ajax only - static function ajaxDeleteBackupFile() - { - if(! isset($_REQUEST['nonce'])){ exit('Invalid request'); } - if ( !wp_verify_nonce( $_REQUEST['nonce'], "wpsBackupFileDelete_nonce")) { exit('Invalid request'); } - - $result = array( - 'type' => '', - 'data' => '' - ); - - if(!empty($_SERVER['HTTP_X_REQUESTED_WITH']) && strtolower($_SERVER['HTTP_X_REQUESTED_WITH']) == 'xmlhttprequest') - { - if ( !isset( $_REQUEST['file'])) { - $result['type'] = 'error'; - $result['data'] = 'Invalid request'; - exit(json_encode($result)); - } - $basePath = self::normalizePath(WPS_PLUGIN_BACKUPS_DIR); - $fileName = self::normalizePath($_REQUEST['file']); - $filePath = $basePath.$fileName; - // prevent directory traversal attacks - $filePath = self::normalizePath(realpath($filePath)); - if(false === ($pos = strpos($filePath, $basePath))){ - $result['type'] = 'error'; - $result['data'] = 'Invalid request'; - exit(json_encode($result)); - } - if(! is_file($filePath)){ - $result['type'] = 'error'; - $result['data'] = 'Invalid request'; - exit(json_encode($result)); - } - - if(true === ($e = @unlink($filePath))){ - $result['type'] = 'success'; - $result['data'] = 'File '.$filePath.' has been deleted.'; - } - else { - $result['type'] = 'error'; - $result['data'] = 'File '.$filePath.' could not be deleted.'; - } - exit(json_encode($result)); - } - exit('Invalid request'); - } -} \ No newline at end of file diff --git a/wp-content/plugins/wp-security-scan/res/inc/WsdWatch.php b/wp-content/plugins/wp-security-scan/res/inc/WsdWatch.php deleted file mode 100644 index 55634e79..00000000 --- a/wp-content/plugins/wp-security-scan/res/inc/WsdWatch.php +++ /dev/null @@ -1,72 +0,0 @@ -get_var($wpdb->prepare("SELECT user_login FROM $t WHERE ID=%d",$userID)); - $user = new WP_User( $userID ); - $userRole = (empty($user->roles[0]) ? '' : $user->roles[0]); - return array( - 'userName' => $username, - 'userRole' => $userRole - ); - } - /** - * @internal - * @param $userID - */ - public static function _watchUserInfoUpdated($userID) - { - // If an admin user's password has been updated - if(! empty($_POST['pass1'])){ - $userInfo = self::_getUserInfo($userID); - $userName = $userInfo['userName']; - $userRole = $userInfo['userRole']; - if($userRole == 'administrator') - { - global $wpsPluginAlertsArray; - $actionName = $wpsPluginAlertsArray['watch_admin_password_update']['name']; - $alertType = $wpsPluginAlertsArray['watch_admin_password_update']['type']; - - if(wpsIsMultisite()){ - global $wpdb; - $blogID = $wpdb->blogid; - $blogName = WpsOption::getOption('blogname', $blogID); - self::alert($actionName, $alertType, WpsSettings::ALERT_MEDIUM, - sprintf(__('Administrator (%s) of blog %s has updated their password.',WpsSettings::TEXT_DOMAIN), $userName, $blogName), - __('

    This alert is generated every time an administrator\'s password is updated.

    ',WpsSettings::TEXT_DOMAIN)); - } - else { - self::alert($actionName, $alertType, WpsSettings::ALERT_MEDIUM, - sprintf(__('Administrator (%s) has updated their password.',WpsSettings::TEXT_DOMAIN), $userName), - __('

    This alert is generated every time an administrator\'s password is updated.

    ',WpsSettings::TEXT_DOMAIN)); - } - } - } - } - -} \ No newline at end of file diff --git a/wp-content/plugins/wp-security-scan/res/inc/WsdWpScanner.php b/wp-content/plugins/wp-security-scan/res/inc/WsdWpScanner.php deleted file mode 100644 index 9ff9a01e..00000000 --- a/wp-content/plugins/wp-security-scan/res/inc/WsdWpScanner.php +++ /dev/null @@ -1,588 +0,0 @@ - self::SCAN_STATE_NONE, - 'SCAN_PROGRESS' => self::SCAN_PROGRESS_NONE, - 'SCAN_RESULT' => self::SCAN_RESULT_NONE, - 'SCAN_TYPE' => 0, - 'SCAN_ID' => 0 - ); - } - - public static function getSetting($name) - { - if(empty(self::$_settings)){ self::$_settings = self::getSettings(); } - $name = strtoupper($name); - return (isset(self::$_settings[$name]) ? self::$_settings[$name] : null); - } - - // Add or update a setting - public static function updateSetting($name, $value, $autoSave = true) - { - if(empty(self::$_settings)){ self::$_settings = self::getSettings(); } - $name = strtoupper($name); - self::$_settings[$name] = $value; - if($autoSave){ - self::saveSettings(); - } - } - - public static function saveSettings() - { - WpsOption::updateOption(WpsSettings::WP_FILE_SCAN_OPTION_NAME, self::$_settings); - } - - public static function isValidState($state) - { - if(empty(self::$_settings)){ self::$_settings = self::getSettings(); } - $state = strtoupper($state); - if(! in_array($state, array(self::SCAN_STATE_DONE, self::SCAN_STATE_IN_PROGRESS, self::SCAN_STATE_WAITING, self::SCAN_STATE_NONE))){ - return false; - } - return true; - } - - public static function isValidProgress($progress) - { - if(empty(self::$_settings)){ self::$_settings = self::getSettings(); } - $progress = strtoupper($progress); - if(! in_array($progress, array(self::SCAN_PROGRESS_NONE, self::SCAN_PROGRESS_ROOT, self::SCAN_PROGRESS_ADMIN, self::SCAN_PROGRESS_CONTENT, self::SCAN_PROGRESS_INCLUDES))){ - return false; - } - return true; - } - - public static function isValidScanType($type) - { - return (in_array($type, array(0,1,2,3,4,5,6,7,8)) ? true : false); - } - - public static function deleteSettings() { - WpsOption::deleteOption(WpsSettings::WP_FILE_SCAN_OPTION_NAME); - wssLog('Settings deleted.'); - } -} - - -class WsdWpScanner extends WsdPlugin -{ - // retrieve the current state of the scan or null if not a valid state - public static function getScanState() - { - $state = WsdWPScanSettings::getSetting('SCAN_STATE'); - if(! WsdWPScanSettings::isValidState($state)){ - return null; - } - return $state; - } - // retrieve the current progress of the scan or null if not a valid progress - public static function getScanProgress() - { - $progress = WsdWPScanSettings::getSetting('SCAN_PROGRESS'); - if(! WsdWPScanSettings::isValidProgress($progress)){ - return null; - } - return $progress; - } - - public static function getScanInfo($scanID) - { - global $wpdb; - $query = "SELECT scanId, scanStartDate, scanEndDate, scanResult, failReason, scanType FROM ".WsdPlugin::getTableName(WpsSettings::SCANS_TABLE_NAME)." WHERE scanId = ".$scanID." ORDER BY scanId DESC"; - return $wpdb->get_row($query); - } - - // - public static function getScans($_limit = 0) - { - global $wpdb; - - //#!++ ignore the currently running scan ID - $currentScanID = WsdWPScanSettings::getSetting('SCAN_ID'); - $where = ''; - if(! empty($currentScanID)){ - $where = " WHERE scanId != ".$currentScanID; - } - $limit = ''; - if(! empty($_limit)){ - $limit = intval($_limit); - if($limit == 0){ - $limit = 1; - } - $limit = " LIMIT 0,".$limit; - } - $query = "SELECT scanId, scanEndDate, scanResult FROM ".WsdPlugin::getTableName(WpsSettings::SCANS_TABLE_NAME).$where." ORDER BY scanId DESC".$limit; - return $wpdb->get_results($query); - } - - - /** - * This method will start and check the scan. wp-cron access only. - */ - public static function checkWpScan() - { - wssLog(__METHOD__.'() called.'); - - $scanState = WsdWPScanSettings::getSetting('SCAN_STATE'); - if($scanState <> WsdWPScanSettings::SCAN_STATE_WAITING){ - $failReason = "Could not start scan. Invalid scan state provided. Expecting: SCAN_STATE_WAITING (".WsdWPScanSettings::SCAN_STATE_WAITING.") received: ".$scanState; - wssLog($failReason); - WpScan::stopScan(false, $failReason); - return false; - } - //#! Start scan - WpScan::startScan(); - } - - // will register a scan - // scan type: the date to check against - public static function registerScan($scanType = 0) - { - // check to see whether or not a scan is pending to start - if(WsdWPScanSettings::getSetting('SCAN_STATE') == WsdWPScanSettings::SCAN_STATE_WAITING){ - return -1; - } - // check to see whether or not there is a scan running already - if(WsdWPScanSettings::getSetting('SCAN_STATE') == WsdWPScanSettings::SCAN_STATE_IN_PROGRESS){ - return 0; - } - if(! WsdWPScanSettings::isValidScanType($scanType)){ - return 1; - } - - global $wpdb; - - // add new scan - $id = null; - //$query = "INSERT INTO ".WsdPlugin::getTableName(WpsSettings::SCANS_TABLE_NAME)." (scanStartDate, scanEndDate, scanType) VALUES(CURRENT_TIMESTAMP(),'0000-00-00 00:00:00')"; - $query = "INSERT INTO ".WsdPlugin::getTableName(WpsSettings::SCANS_TABLE_NAME)." (scanStartDate, scanType) VALUES(CURRENT_TIMESTAMP(),$scanType)"; - $result = $wpdb->query($query); - if(! empty($result)){ - $query = "SELECT scanId FROM ".WsdPlugin::getTableName(WpsSettings::SCANS_TABLE_NAME)." WHERE scanResult = 0 ORDER BY scanId DESC;"; - $id = $wpdb->get_var($query); - } - - if(empty($id)){ - wssLog('Internal Error: could not retrieve the ID for the last added scan.', array('function'=>__METHOD__, 'line'=>__LINE__)); - return 2; - } - - // update settings - WsdWPScanSettings::updateSetting('SCAN_ID', $id, false); - WsdWPScanSettings::updateSetting('SCAN_TYPE', $scanType); - WsdWPScanSettings::updateSetting('SCAN_STATE', WsdWPScanSettings::SCAN_STATE_WAITING); - - return 3; - } - - static function deleteAllScans() - { - wssLog(__METHOD__.'() triggered'); - - global $wpdb; - $scanTable = WsdPlugin::getTableName(WpsSettings::SCAN_TABLE_NAME); - $scansTable = WsdPlugin::getTableName(WpsSettings::SCANS_TABLE_NAME); - - wssLog('Truncate tables.'); - - $q = "TRUNCATE $scanTable"; - $result = $wpdb->query($q); - if(false === $result){ - wssLog('MySQL Error: ', array('query'=>$q, 'error'=>$wpdb->last_error)); - return false; - } - $q = "TRUNCATE $scansTable"; - $result = $wpdb->query($q); - if(false === $result){ - wssLog('MySQL Error: ', array('query'=>$q, 'error'=>$wpdb->last_error)); - return false; - } - wssLog('Tables truncated. Done deleting scans.'); - return true; - } - - /** retrieve the scan id from scans table */ - public static function getLastScanID_table() - { - global $wpdb; - $query = "SELECT scanId FROM ".WsdPlugin::getTableName(WpsSettings::SCANS_TABLE_NAME)." ORDER BY scanId DESC;"; - $result = $wpdb->get_var($query); - return (empty($result) ? 0 : $result); - } - - public static function getLastCompletedScanID() - { - global $wpdb; - $query = "SELECT scanId FROM ".WsdPlugin::getTableName(WpsSettings::SCANS_TABLE_NAME)." WHERE scanResult = 1 ORDER BY scanId DESC;"; - $result = $wpdb->get_var($query); - return (empty($result) ? 0 : $result); - } - - public static function isValidScan($scanID) - { - $scan_id = WsdWPScanSettings::getSetting('SCAN_ID'); - if($scanID == $scan_id){ - return false; - } - global $wpdb; - $query = $wpdb->prepare("SELECT scanId FROM ".WsdPlugin::getTableName(WpsSettings::SCANS_TABLE_NAME)." WHERE scanId = %d",$scanID); - $result = $wpdb->get_var($query); - return (empty($result) ? false : true); - } - - public static function getFailedEntries($scanID) - { - global $wpdb; - $query = $wpdb->prepare("SELECT filePath, dateModified, fileNotFound FROM ".WsdPlugin::getTableName(WpsSettings::SCAN_TABLE_NAME)." WHERE scanId = %d ORDER BY dateModified",$scanID); - return $wpdb->get_results($query); - } - - public static function deleteScan($scanID) - { - global $wpdb; - $query1 = $wpdb->prepare("DELETE FROM ".WsdPlugin::getTableName(WpsSettings::SCAN_TABLE_NAME)." WHERE scanId = %d",$scanID); - $query2 = $wpdb->prepare("DELETE FROM ".WsdPlugin::getTableName(WpsSettings::SCANS_TABLE_NAME)." WHERE scanId = %d",$scanID); - if(($wpdb->query($query1) !== false) && ($wpdb->query($query2) !== false)){ - return true; - } - return false; - } -} - -class WpScan -{ - private static $_scanID = 0; - - public static function startScan() - { - wssLog(__METHOD__.'() triggered '.PHP_EOL.str_repeat('=', 50)); - - $settings = WsdWPScanSettings::getSettings(); - - $scanID = $settings['SCAN_ID']; - $scanState = $settings['SCAN_STATE']; - $scanProgress = $settings['SCAN_PROGRESS']; - $scanResult = $settings['SCAN_RESULT']; - $scanType = $settings['SCAN_TYPE']; - self::$_scanID = $scanID; - - wssLog('SCAN DATA', array( - '$scanID' => $scanID, - '$scanState' => $scanState, - '$scanProgress' => $scanProgress, - '$scanResult' => $scanResult, - '$scanType' => $scanType, - )); - - // if scan id == 0 there is no scan registered - if(empty($scanID)) - { - $failReason = "Internal Error: No scan ID provided."; - wssLog('No scan ID. Ignoring the scan start request.'); - self::stopScan(false, $failReason); - return false; - } - - //#! if scan state is none - if($scanState == WsdWPScanSettings::SCAN_STATE_NONE) - { - wssLog('Invalid scan state. Ignoring the scan start request.', array( - 'state' => 'SCAN_STATE_NONE' - )); - return false; - } - - //#! if scan in progress - if($scanState == WsdWPScanSettings::SCAN_STATE_IN_PROGRESS) - { - wssLog('Scan is running. Ignoring the scan start request.', array( - 'state' => 'SCAN_STATE_IN_PROGRESS', - 'progress' => $scanProgress - )); - return false; - } - - //#! Start scan - //============================= - - global $wp_version; - wssLog('WordPress version installed:', array('version'=>$wp_version)); - if(empty($wp_version)){ - $failReason = __("Could not retrieve the WordPress version.",WpsSettings::TEXT_DOMAIN); - wssLog('Invalid WordPress version detected.'); - self::stopScan(false, $failReason); - return false; - } - - wssLog('Starting scan.', array('ID'=>self::$_scanID)); - - @ignore_user_abort(true); - @set_time_limit(WpsSettings::WPS_MAX_TIME_EXEC_LIMIT); - - //#! update scan state - WsdWPScanSettings::updateSetting('SCAN_STATE', WsdWPScanSettings::SCAN_STATE_IN_PROGRESS); - - //#! Request the json file from server depending on the current WP version - $json = null; - $url = WpsSettings::getJsonRepoUrl()."{$wp_version}.json"; - wssLog('Retrieving json file.', array('path'=>$url)); - $c = @file_get_contents($url); - if(empty($c)){ - $reason = sprintf(__("Error retrieving the json file from server for the detected WordPress version: %s. Scan aborted.",WpsSettings::TEXT_DOMAIN),$wp_version); - wssLog($reason); - self::stopScan(false, $reason); - return false; - } - else { - $data = json_decode($c); - wssLog('Json file retrieved from path: '.$url); - - if(is_null($data)){ - $failReason = __('Error decoding the json file. The file might be empty or corrupted.',WpsSettings::TEXT_DOMAIN); - wssLog($failReason,array('path'=>$url)); - self::stopScan(false, $failReason); - return false; - } - - //#! Ensure file is valid - if(isset($data->root) && isset($data->wp_admin) && isset($data->wp_content) && isset($data->wp_includes)) - { - $rootFiles = $data->root; - $wpAdminFiles = $data->wp_admin; - $wpContentFiles = $data->wp_content; - $wpIncludesFiles = $data->wp_includes; - - if(empty($rootFiles)|| empty($wpAdminFiles) || empty($wpContentFiles) || empty($wpIncludesFiles)){ - $failReason = __('Invalid json file retrieved from server.',WpsSettings::TEXT_DOMAIN); - wssLog($failReason,array('path'=>$url)); - self::stopScan(false, $failReason); - return false; - } - - //#! mark as ok for GC - $data = null; - - $now = time(); - $h24 = 24 * 60 * 60; - $since = 0; - if($scanType == 0) { $since = strtotime('midnight'); } - elseif($scanType == 1){ $since = $now - $h24; } - elseif($scanType == 2){ $since = $now - 2*$h24; } - elseif($scanType == 3){ $since = $now - 3*$h24; } - elseif($scanType == 4){ $since = $now - 4*$h24; } - elseif($scanType == 5){ $since = $now - 5*$h24; } - elseif($scanType == 6){ $since = $now - 6*$h24; } - elseif($scanType == 7){ $since = $now - 7*$h24; } - elseif($scanType == 8){ $since = strtotime("-1 months") - $h24 - $now; } - - WsdWPScanSettings::updateSetting('SCAN_PROGRESS',WsdWPScanSettings::SCAN_PROGRESS_ROOT, true); - self::_checkFiles(ABSPATH, $rootFiles, $since, true); - wssLog("root directory scan complete"); - - WsdWPScanSettings::updateSetting('SCAN_PROGRESS',WsdWPScanSettings::SCAN_PROGRESS_ADMIN); - self::_checkFiles(ABSPATH.'wp-admin/',$wpAdminFiles, $since, false, false, true); - wssLog("wp-admin directory scan complete"); - - WsdWPScanSettings::updateSetting('SCAN_PROGRESS',WsdWPScanSettings::SCAN_PROGRESS_CONTENT); - self::_checkFiles(ABSPATH.'wp-content/',$wpContentFiles, $since,false,true); - wssLog("wp-content directory scan complete"); - - WsdWPScanSettings::updateSetting('SCAN_PROGRESS',WsdWPScanSettings::SCAN_PROGRESS_INCLUDES); - self::_checkFiles(ABSPATH.'wp-includes/',$wpIncludesFiles, $since); - wssLog("wp-includes directory scan complete"); - - //#! Mark scan as completed - self::stopScan(true); - return true; - } - else { - $failReason = __('Invalid json file retrieved from server.',WpsSettings::TEXT_DOMAIN); - wssLog($failReason,array('path'=>$url)); - self::stopScan(false, $failReason); - return false; - } - } - } - - //#! - private static function _checkFiles($basePath, array $files, $fileModifiedSince, $isWpRoot = false, $isWpContent = false, $isWpAdmin = false) - { - wssLog(__METHOD__.'(). Scanning: '.WsdUtil::normalizePath($basePath)); - foreach($files as $file) - { - $_file = $basePath.$file; - $_file = WsdUtil::normalizePath($_file); - if(! is_file($_file)) - { - // if this is the root and wp-config.php file... - if($isWpRoot) - { - // safely ignore this file - if(strcasecmp($file,'wp-config-sample.php')==0){ - wssLog('wp-config-sample.php file is missing but can be ignored. Skipping file check.'); - continue; - } - elseif(strcasecmp($file,'wp-config.php')==0) - { - // check one level above - $path = realpath('../'.ABSPATH).'/'.$file; - if(is_file($path)){ - $_file = $path; - } - else { - //#! Mark file not found - self::_markFileNotFound($_file); - continue; - } - } - elseif(strcasecmp($file,'readme.html')==0){ - wssLog('readme.html file is missing but can be ignored. Skipping file check.'); - continue; - } - } - elseif($isWpContent) - { - // Ignore WP's default themes and plugins if not found - if(WsdUtil::canIgnoreScanPath($_file)){ - wssLog($_file.' file is missing but can be ignored. Skipping file check.'); - continue; - } - } - elseif($isWpAdmin) - { - // safely ignore marked files from /wp-admin - if(strcasecmp($file,'install.php')==0){ - wssLog('wp-admin/install.php file is missing but can be ignored. Skipping file check.'); - continue; - } - // safely ignore marked files from /wp-admin - elseif(strcasecmp($file,'upgrade.php')==0){ - wssLog('wp-admin/upgrade.php file is missing but can be ignored. Skipping file check.'); - continue; - } - } - //#! Mark file not found - self::_markFileNotFound($_file); - continue; - } - $mdate = filemtime($_file); - if($mdate > $fileModifiedSince){ - //#! Mark file as modified - self::_markFileModified($_file, $mdate); - } - } - } - - private static function _markFileNotFound($filePath) - { - global $wpdb; - $query = $wpdb->prepare( - "INSERT INTO ".WsdPlugin::getTableName(WpsSettings::SCAN_TABLE_NAME)." (scanId, filePath, fileNotFound) VALUES (%d,'%s',%d)" - ,self::$_scanID, $filePath, 1); - $wpdb->query($query); - } - - private static function _markFileModified($filePath, $modifiedDate) - { - global $wpdb; - $query = $wpdb->prepare( - "INSERT INTO ".WsdPlugin::getTableName(WpsSettings::SCAN_TABLE_NAME)." (scanId, filePath, dateModified) VALUES (%d,'%s', '%s')" - ,self::$_scanID, $filePath, date('Y-m-d H:i:s', $modifiedDate)); - $wpdb->query($query); - } - - - private static function _markScanFailed($scanID, $failReason = '') - { - wssLog(__METHOD__.'() triggered.', array('failReason'=>$failReason)); - global $wpdb; - if(empty($failReason)){ - $query = $wpdb->prepare("UPDATE ".WsdPlugin::getTableName(WpsSettings::SCANS_TABLE_NAME)." SET scanEndDate = CURRENT_TIMESTAMP() WHERE scanId = %d", self::$_scanID); - } - else { - $query = $wpdb->prepare("UPDATE ".WsdPlugin::getTableName(WpsSettings::SCANS_TABLE_NAME)." SET scanEndDate = CURRENT_TIMESTAMP(), failReason = '%s' WHERE scanId = %d" - ,$failReason, $scanID); - - } - $wpdb->query($query); - } - private static function _markScanCompleted() - { - $m = __METHOD__.'() '; - wssLog($m.'triggered.'); - global $wpdb; - $query = $wpdb->prepare("UPDATE ".WsdPlugin::getTableName(WpsSettings::SCANS_TABLE_NAME)." SET scanEndDate = CURRENT_TIMESTAMP(), scanResult = 1 WHERE scanId = %d", self::$_scanID); - $wpdb->query($query); - wssLog('Scan completed', array('ID'=>self::$_scanID)); - } - - // php shutdown function - // mark scan as failed and delete settings - public static function stopScan($completed = false, $failReason = '') - { - $scanID = self::$_scanID; - if(empty($scanID)){ - $optData = WpsOption::getOption(WpsSettings::WP_FILE_SCAN_OPTION_NAME); - if(empty($optData)){ - wssLog('Empty $optData. Checking db table for any incomplete scan.'); - $sid = WsdWpScanner::getLastScanID_table(); - if(empty($sid)){ - wssLog('No incomplete scans found either.'); - return; - } - else { wssLog("Incomplete scan found: $sid"); $scanID = $sid; } - } - else { - $scanID = $optData['SCAN_ID']; - if(empty($scanID)){ - return; - } - } - } - $m = __METHOD__.'() '; - wssLog($m.'triggered.'); - if($completed){ - self::_markScanCompleted(); - } - else { wssLog('Fail reason: '.$failReason); self::_markScanFailed($scanID,$failReason); } - - WsdWPScanSettings::deleteSettings(); - wssLog('Scan ('.$scanID.') marked as '.($completed ? 'completed' : 'failed').' and options deleted.'.PHP_EOL.str_repeat('=', 50)); - } -} \ No newline at end of file diff --git a/wp-content/plugins/wp-security-scan/res/inc/alerts.php b/wp-content/plugins/wp-security-scan/res/inc/alerts.php deleted file mode 100644 index b20232da..00000000 --- a/wp-content/plugins/wp-security-scan/res/inc/alerts.php +++ /dev/null @@ -1,67 +0,0 @@ - array('name' => 'check_username_admin ', 'type' => WpsSettings::ALERT_TYPE_OVERWRITE ), -// WsdCheck::tablePrefix - 'check_table_prefix' => array('name' => 'check_table_prefix', 'type' => WpsSettings::ALERT_TYPE_OVERWRITE ), -// WsdCheck::currentVersion - 'check_wp_current_version' => array('name' => 'check_wp_current_version', 'type' => WpsSettings::ALERT_TYPE_OVERWRITE ), -// WsdCheck::files - 'check_index_wp_content' => array('name' => 'check_index_wp_content', 'type' => WpsSettings::ALERT_TYPE_OVERWRITE ), -// WsdCheck::files - 'check_index_wp_content' => array('name' => 'check_index_wp_content', 'type' => WpsSettings::ALERT_TYPE_OVERWRITE ), -// WsdCheck::files - 'check_index_wp_plugins' => array('name' => 'check_index_wp_plugins', 'type' => WpsSettings::ALERT_TYPE_OVERWRITE ), -// WsdCheck::files - 'check_index_wp_themes' => array('name' => 'check_index_wp_themes', 'type' => WpsSettings::ALERT_TYPE_OVERWRITE ), -// WsdCheck::files - alert issued only if the wp-content/uploads directory exists - 'check_index_wp_uploads' => array('name' => 'check_index_wp_uploads', 'type' => WpsSettings::ALERT_TYPE_OVERWRITE ), -// WsdCheck::files - 'check_htaccess_wp_admin' => array('name' => 'check_htaccess_wp_admin', 'type' => WpsSettings::ALERT_TYPE_OVERWRITE ), -// WsdCheck::files - 'check_readme_wp_root' => array('name' => 'check_readme_wp_root', 'type' => WpsSettings::ALERT_TYPE_OVERWRITE ), -// WsdCheck:: - 'check_wp_admin_install' => array('name' => 'check_wp_admin_install', 'type' => WpsSettings::ALERT_TYPE_OVERWRITE ), -// WsdCheck:: - 'check_wp_admin_upgrade' => array('name' => 'check_wp_admin_upgrade', 'type' => WpsSettings::ALERT_TYPE_OVERWRITE ), - -// WsdSecurity::fix_hideWpVersion - 'fix_wp_version_hidden' => array('name' => 'fix_wp_version_hidden', 'type' => WpsSettings::ALERT_TYPE_OVERWRITE ), -// WsdSecurity::fix_removeWpMetaGeneratorsFrontend - 'fix_wp_generators_frontend' => array('name' => 'fix_wp_generators_frontend', 'type' => WpsSettings::ALERT_TYPE_OVERWRITE ), -// WsdSecurity::fix_removeReallySimpleDiscovery - 'fix_wp_rsd_frontend' => array('name' => 'fix_wp_rsd_frontend', 'type' => WpsSettings::ALERT_TYPE_OVERWRITE ), -// WsdSecurity::fix_removeWindowsLiveWriter - 'fix_wp_wlw_frontend' => array('name' => 'fix_wp_wlw_frontend', 'type' => WpsSettings::ALERT_TYPE_OVERWRITE ), -// WsdSecurity::fix_disableErrorReporting - 'fix_wp_error_reporting' => array('name' => 'fix_wp_error_reporting', 'type' => WpsSettings::ALERT_TYPE_OVERWRITE ), -// WsdSecurity::fix_removeCoreUpdateNotification - 'fix_wp_core_update_notif' => array('name' => 'fix_wp_core_update_notif', 'type' => WpsSettings::ALERT_TYPE_OVERWRITE ), -// WsdSecurity::fix_removePluginUpdateNotifications - 'fix_wp_plugins_update_notif' => array('name' => 'fix_wp_plugins_update_notif', 'type' => WpsSettings::ALERT_TYPE_OVERWRITE ), -// WsdSecurity::fix_removeThemeUpdateNotifications - 'fix_wp_themes_update_notif' => array('name' => 'fix_wp_themes_update_notif', 'type' => WpsSettings::ALERT_TYPE_OVERWRITE ), -// WsdSecurity::fix_removeLoginErrorNotificationsFrontEnd - 'fix_wp_login_errors' => array('name' => 'fix_wp_login_errors', 'type' => WpsSettings::ALERT_TYPE_OVERWRITE ), -// WsdSecurity::fix_hideAdminNotifications - 'fix_wp_admin_notices' => array('name' => 'fix_wp_admin_notices', 'type' => WpsSettings::ALERT_TYPE_OVERWRITE ), -// WsdSecurity::fix_preventDirectoryListing - 'fix_wp_dir_listing' => array('name' => 'fix_wp_dir_listing', 'type' => WpsSettings::ALERT_TYPE_OVERWRITE ), -// WsdSecurity::fix_preventDirectoryListing - 'fix_wp_index_content' => array('name' => 'fix_wp_index_content', 'type' => WpsSettings::ALERT_TYPE_OVERWRITE ), -// WsdSecurity::fix_preventDirectoryListing - 'fix_wp_index_plugins' => array('name' => 'fix_wp_index_plugins', 'type' => WpsSettings::ALERT_TYPE_OVERWRITE ), -// WsdSecurity::fix_preventDirectoryListing - 'fix_wp_index_themes' => array('name' => 'fix_wp_index_themes', 'type' => WpsSettings::ALERT_TYPE_OVERWRITE ), -// WsdSecurity::fix_preventDirectoryListing - alert issued only if the wp-content/uploads directory exists - 'fix_wp_index_uploads' => array('name' => 'fix_wp_index_uploads', 'type' => WpsSettings::ALERT_TYPE_OVERWRITE ), -// WsdSecurity::fix_removeWpVersionFromLinks - 'fix_remove_wp_version_links' => array('name' => 'fix_remove_wp_version_links', 'type' => WpsSettings::ALERT_TYPE_OVERWRITE ), -// WsdSecurity::fix_emptyReadmeFileFromRoot - 'fix_empty_root_readme_file' => array('name' => 'fix_empty_root_readme_file', 'type' => WpsSettings::ALERT_TYPE_OVERWRITE ), - - -// WsdWatch::userPasswordUpdate - 'watch_admin_password_update' => array('name' => 'watch_admin_password_update', 'type' => WpsSettings::ALERT_TYPE_STACK ), -); \ No newline at end of file diff --git a/wp-content/plugins/wp-security-scan/res/inc/index.php b/wp-content/plugins/wp-security-scan/res/inc/index.php deleted file mode 100644 index fe0ab8ea..00000000 --- a/wp-content/plugins/wp-security-scan/res/inc/index.php +++ /dev/null @@ -1 +0,0 @@ - 60, - 'display' => __('Every 1 minute',WpsSettings::TEXT_DOMAIN) - ); - //#! @see WsdWpScanner::registerScan() - $schedules['5m'] = array( - 'interval' => 300, - 'display' => __('Every 5 minutes',WpsSettings::TEXT_DOMAIN) - ); - #! used for admin user check - //#! @see WsdCheck::adminUsername() - $schedules['8h'] = array( // The name to be used in code - 'interval' => 28800, // Intervals: in seconds - 'display' => __('Every 8 hours',WpsSettings::TEXT_DOMAIN) // display name - ); - return $schedules; -} -add_filter( 'cron_schedules', 'wpsPlugin_addCronIntervals' ); - -function wpsAdminNotice($message=''){ if(!empty($message)){ echo '

    '.$message.'

    '; } } -function wpsAdminNoticeError($error){ if(!empty($error)){ echo '

    '.$error.'

    ';} } -function wpsDisplayInstallErrorNotices() { - if ($notices = WpsOption::getOption(WpsSettings::PLUGIN_ERROR_NOTICE_OPTION, array())) { - if(empty($notices)){ return false; } - foreach ($notices as $notice) { wpsAdminNoticeError($notice); } - return true; - } - return false; -} -/* Check to see whether or not the plugin was installed successfully. */ -function wpsIsValidInstall(){ - if(wpsIsMultisite()){ - $_ = WpsOption::getOption('WPS_NETWORK_INSTALL'); - if(empty($_)){ - return false; - } - } - return true; -} - -/** - * make sure we can display any of the plugin's pages - * @return bool - */ -function wpsCanDisplayPage() -{ - if(! WsdUtil::canLoad()) { return false; } - if(! WsdUtil::isAdministrator()){ return false; } - if(! wpsIsValidInstall()){ - wpsDisplayInstallErrorNotices(); - return false; - } - return true; -} - -//#! Logging method -function wssLog($message, $data = null) -{ - if(! WpsSettings::WPS_DEBUG){ - return; - } - $m = '['.@date("M d @H:i:s").'] Debug: '.$message; - if(!is_null($data)){ - $m .= ' Data: '.var_export($data, true); - } - $m .= PHP_EOL; - error_log($m, 3, WPS_PLUGIN_DIR.'debug.log'); -} - -//#! Shutdown function called on each script exit -function wssPlugin_shutdown() -{ - $error = error_get_last(); - if(!empty($error)) - { - // Only fatal errors, otherwise it will kill every scan - if($error['type'] === E_ERROR) - { - if(! empty($error['message'])) - { - $data = array( - 'type' => $error["type"], - 'file' => (empty($error["file"]) ? '' : $error["file"]), - 'line' => (empty($error["line"]) ? '' : $error["line"]), - 'message' => $error["message"], - ); - wssLog(__FUNCTION__.'() triggered.'); - wssLog('Shutdown function called by system.', $data); - WpScan::stopScan(false, $data['message']); - } - } - } -} -register_shutdown_function('wssPlugin_shutdown'); - - -/* - * @since 4.0.2 - * MultiSite functions - */ -function wpsGetBasePrefix() { global $wpdb; return $wpdb->base_prefix; } -function wpsIsMultisite(){ return (function_exists('is_multisite') && is_multisite()); } -function wpsIsMainSite(){ global $wpdb; return($wpdb->prefix == $wpdb->base_prefix); } -function _wpsSiteActivate($mu = false, $blogID = 1) -{ - wssLog(__FUNCTION__."() called with args: ",array('$mu'=>$mu, '$blogID'=>$blogID)); - //#! check if already installed if MU - if($mu){ return WsdPlugin::networkActivate(); } - else { return WsdPlugin::activate(); } -} -function _wpsSiteDeactivate($mu = false, $blogID=1) -{ - WsdScheduler::unregisterCronTasks(); - if($mu){ - delete_blog_option($blogID, 'WPS_NETWORK_INSTALL'); - delete_blog_option($blogID, 'WPS_PLUGIN_ACTIVATED'); - delete_blog_option($blogID, WpsSettings::WP_FILE_SCAN_OPTION_NAME); - delete_blog_option($blogID, WpsSettings::PLUGIN_ERROR_NOTICE_OPTION); - delete_blog_option($blogID, WpsSettings::CAN_RUN_TASKS_OPTION_NAME); - delete_blog_option($blogID, WpsSettings::ENABLE_LIVE_TRAFFIC); - } - else { - delete_option('WPS_PLUGIN_ACTIVATED'); - delete_option(WpsSettings::WP_FILE_SCAN_OPTION_NAME); - delete_option(WpsSettings::PLUGIN_ERROR_NOTICE_OPTION); - delete_option(WpsSettings::CAN_RUN_TASKS_OPTION_NAME); - delete_option(WpsSettings::ENABLE_LIVE_TRAFFIC); - } -} -function wpsNetworkActivate($networkwide=false){ - if (wpsIsMultisite()) - { - global $wpdb; - if($networkwide) - { - $old_blog = $wpdb->blogid; - // Get all blog ids - $blogIds = $wpdb->get_col("SELECT blog_id FROM $wpdb->blogs"); - foreach ($blogIds as $blog_id) { - switch_to_blog($blog_id); - update_blog_option($blog_id, 'WPS_PLUGIN_ACTIVATED', 1); - delete_blog_option($blog_id, WpsSettings::PLUGIN_ERROR_NOTICE_OPTION); - } - switch_to_blog($old_blog); - - if(_wpsSiteActivate(true, $old_blog)) - { - add_blog_option($old_blog, 'WPS_KEEP_NUM_ENTRIES_LT',500); - add_blog_option($old_blog, 'WPS_REFRESH_RATE_AJAX_LT',10); - - add_blog_option($old_blog, 'WPS_NETWORK_INSTALL', 1); - add_blog_option($old_blog, 'WPS_PLUGIN_ACTIVATED', 1); - add_blog_option($old_blog, WpsSettings::ENABLE_LIVE_TRAFFIC, 1); - } - else { - $notices = get_blog_option($wpdb->blogid, WpsSettings::PLUGIN_ERROR_NOTICE_OPTION, array()); - $notices[]= '

    '.WPS_PLUGIN_NAME.'

    Error: An error has occurred while installing the plugin.

    '; - update_site_option($wpdb->blogid, WpsSettings::PLUGIN_ERROR_NOTICE_OPTION, $notices); - } - } - else { - wp_redirect(network_admin_url('plugins.php')); - exit; - } - } - else { - add_option('WPS_KEEP_NUM_ENTRIES_LT',500); - add_option('WPS_REFRESH_RATE_AJAX_LT',10); - add_option(WpsSettings::ENABLE_LIVE_TRAFFIC,1); - _wpsSiteActivate(); - } -} -function wpsNetworkDeactivate($networkwide=false){ - if (wpsIsMultisite() && $networkwide) { - global $wpdb; - $old_blog = $wpdb->blogid; - // network deactivate - $blogIds = $wpdb->get_col("SELECT blog_id FROM $wpdb->blogs"); - foreach ($blogIds as $blog_id) { - switch_to_blog($blog_id); - delete_blog_option($blog_id, 'WPS_PLUGIN_ACTIVATED'); - delete_blog_option($blog_id, WpsSettings::PLUGIN_ERROR_NOTICE_OPTION); - } - // main site - switch_to_blog($old_blog); - _wpsSiteDeactivate(true, $old_blog); - } - else { _wpsSiteDeactivate(); } -} - -function wpsCreateSiteMenu(){ - $reqCap = 'administrator'; - if (current_user_can($reqCap) && function_exists('add_menu_page')){ - add_menu_page('WP Security', 'WP Security', $reqCap, WPS_PLUGIN_PREFIX, array('WsdPlugin','pageMain'), WsdUtil::imageUrl('logo-small.png')); - add_submenu_page(WPS_PLUGIN_PREFIX, 'Dashboard', 'Dashboard', $reqCap, WPS_PLUGIN_PREFIX, array('WsdPlugin','pageMain')); - add_submenu_page(WPS_PLUGIN_PREFIX, 'WP Info', 'WP Info', $reqCap, WPS_PLUGIN_PREFIX.'scanner', array('WsdPlugin','pageWpInfo')); - add_submenu_page(WPS_PLUGIN_PREFIX, 'Live traffic', 'Live traffic', $reqCap, WPS_PLUGIN_PREFIX.'live_traffic', array('WsdPlugin','pageLiveTraffic')); - add_submenu_page(WPS_PLUGIN_PREFIX, 'Blog', 'Blog', $reqCap, WPS_PLUGIN_PREFIX.'blog', array('WsdPlugin','pageBlog')); - add_submenu_page(WPS_PLUGIN_PREFIX, 'About', 'About', $reqCap, WPS_PLUGIN_PREFIX.'about', array('WsdPlugin','pageAbout')); - } -} -function wpsCreateNetworkMenu(){ - $reqCap = 'administrator'; - if (current_user_can($reqCap) && function_exists('add_menu_page')){ - add_menu_page('WP Security', 'WP Security', $reqCap, WPS_PLUGIN_PREFIX, array('WsdPlugin','pageMain'), WsdUtil::imageUrl('logo-small.png')); - add_submenu_page(WPS_PLUGIN_PREFIX, 'Dashboard', 'Dashboard', $reqCap, WPS_PLUGIN_PREFIX, array('WsdPlugin','pageMain')); - add_submenu_page(WPS_PLUGIN_PREFIX, 'Database', 'Database', $reqCap, WPS_PLUGIN_PREFIX.'database', array('WsdPlugin','pageDatabase')); - add_submenu_page(WPS_PLUGIN_PREFIX, 'WP Info', 'WP Info', $reqCap, WPS_PLUGIN_PREFIX.'scanner', array('WsdPlugin','pageWpInfo')); - add_submenu_page(WPS_PLUGIN_PREFIX, 'WP File Scan', 'WP File Scan', $reqCap, WPS_PLUGIN_PREFIX.'wpscan', array('WsdPlugin','pageWpFileScan')); - add_submenu_page(WPS_PLUGIN_PREFIX, 'Live traffic', 'Live traffic', $reqCap, WPS_PLUGIN_PREFIX.'live_traffic', array('WsdPlugin','pageLiveTraffic')); - add_submenu_page(WPS_PLUGIN_PREFIX, 'Blog', 'Blog', $reqCap, WPS_PLUGIN_PREFIX.'blog', array('WsdPlugin','pageBlog')); - add_submenu_page(WPS_PLUGIN_PREFIX, 'Settings', 'Settings', $reqCap, WPS_PLUGIN_PREFIX.'settings', array('WsdPlugin','pageSettings')); - add_submenu_page(WPS_PLUGIN_PREFIX, 'About', 'About', $reqCap, WPS_PLUGIN_PREFIX.'about', array('WsdPlugin','pageAbout')); - } -} - -function wpsRunFixes(){ - $methods = WpsSettings::getSettingsList(); - if(empty($methods)){ return false;} - foreach($methods as $method){ - add_action('init', array('WsdSecurity',$method['name'])); - } -} - diff --git a/wp-content/plugins/wp-security-scan/res/index.php b/wp-content/plugins/wp-security-scan/res/index.php deleted file mode 100644 index fe0ab8ea..00000000 --- a/wp-content/plugins/wp-security-scan/res/index.php +++ /dev/null @@ -1 +0,0 @@ -this.$items.length-1||t<0)return;return this.sliding?this.$element.one("slid",function(){r.to(t)}):n==t?this.pause().cycle():this.slide(t>n?"next":"prev",e(this.$items[t]))},pause:function(t){return t||(this.paused=!0),this.$element.find(".next, .prev").length&&e.support.transition.end&&(this.$element.trigger(e.support.transition.end),this.cycle(!0)),clearInterval(this.interval),this.interval=null,this},next:function(){if(this.sliding)return;return this.slide("next")},prev:function(){if(this.sliding)return;return this.slide("prev")},slide:function(t,n){var r=this.$element.find(".item.active"),i=n||r[t](),s=this.interval,o=t=="next"?"left":"right",u=t=="next"?"first":"last",a=this,f;this.sliding=!0,s&&this.pause(),i=i.length?i:this.$element.find(".item")[u](),f=e.Event("slide",{relatedTarget:i[0],direction:o});if(i.hasClass("active"))return;this.$indicators.length&&(this.$indicators.find(".active").removeClass("active"),this.$element.one("slid",function(){var t=e(a.$indicators.children()[a.getActiveIndex()]);t&&t.addClass("active")}));if(e.support.transition&&this.$element.hasClass("slide")){this.$element.trigger(f);if(f.isDefaultPrevented())return;i.addClass(t),i[0].offsetWidth,r.addClass(o),i.addClass(o),this.$element.one(e.support.transition.end,function(){i.removeClass([t,o].join(" ")).addClass("active"),r.removeClass(["active",o].join(" ")),a.sliding=!1,setTimeout(function(){a.$element.trigger("slid")},0)})}else{this.$element.trigger(f);if(f.isDefaultPrevented())return;r.removeClass("active"),i.addClass("active"),this.sliding=!1,this.$element.trigger("slid")}return s&&this.cycle(),this}};var n=e.fn.carousel;e.fn.carousel=function(n){return this.each(function(){var r=e(this),i=r.data("carousel"),s=e.extend({},e.fn.carousel.defaults,typeof n=="object"&&n),o=typeof n=="string"?n:s.slide;i||r.data("carousel",i=new t(this,s)),typeof n=="number"?i.to(n):o?i[o]():s.interval&&i.pause().cycle()})},e.fn.carousel.defaults={interval:5e3,pause:"hover"},e.fn.carousel.Constructor=t,e.fn.carousel.noConflict=function(){return e.fn.carousel=n,this},e(document).on("click.carousel.data-api","[data-slide], [data-slide-to]",function(t){var n=e(this),r,i=e(n.attr("data-target")||(r=n.attr("href"))&&r.replace(/.*(?=#[^\s]+$)/,"")),s=e.extend({},i.data(),n.data()),o;i.carousel(s),(o=n.attr("data-slide-to"))&&i.data("carousel").pause().to(o).cycle(),t.preventDefault()})}(window.jQuery),!function(e){"use strict";var t=function(t,n){this.$element=e(t),this.options=e.extend({},e.fn.collapse.defaults,n),this.options.parent&&(this.$parent=e(this.options.parent)),this.options.toggle&&this.toggle()};t.prototype={constructor:t,dimension:function(){var e=this.$element.hasClass("width");return e?"width":"height"},show:function(){var t,n,r,i;if(this.transitioning||this.$element.hasClass("in"))return;t=this.dimension(),n=e.camelCase(["scroll",t].join("-")),r=this.$parent&&this.$parent.find("> .accordion-group > .in");if(r&&r.length){i=r.data("collapse");if(i&&i.transitioning)return;r.collapse("hide"),i||r.data("collapse",null)}this.$element[t](0),this.transition("addClass",e.Event("show"),"shown"),e.support.transition&&this.$element[t](this.$element[0][n])},hide:function(){var t;if(this.transitioning||!this.$element.hasClass("in"))return;t=this.dimension(),this.reset(this.$element[t]()),this.transition("removeClass",e.Event("hide"),"hidden"),this.$element[t](0)},reset:function(e){var t=this.dimension();return this.$element.removeClass("collapse")[t](e||"auto")[0].offsetWidth,this.$element[e!==null?"addClass":"removeClass"]("collapse"),this},transition:function(t,n,r){var i=this,s=function(){n.type=="show"&&i.reset(),i.transitioning=0,i.$element.trigger(r)};this.$element.trigger(n);if(n.isDefaultPrevented())return;this.transitioning=1,this.$element[t]("in"),e.support.transition&&this.$element.hasClass("collapse")?this.$element.one(e.support.transition.end,s):s()},toggle:function(){this[this.$element.hasClass("in")?"hide":"show"]()}};var n=e.fn.collapse;e.fn.collapse=function(n){return this.each(function(){var r=e(this),i=r.data("collapse"),s=e.extend({},e.fn.collapse.defaults,r.data(),typeof n=="object"&&n);i||r.data("collapse",i=new t(this,s)),typeof n=="string"&&i[n]()})},e.fn.collapse.defaults={toggle:!0},e.fn.collapse.Constructor=t,e.fn.collapse.noConflict=function(){return e.fn.collapse=n,this},e(document).on("click.collapse.data-api","[data-toggle=collapse]",function(t){var n=e(this),r,i=n.attr("data-target")||t.preventDefault()||(r=n.attr("href"))&&r.replace(/.*(?=#[^\s]+$)/,""),s=e(i).data("collapse")?"toggle":n.data();n[e(i).hasClass("in")?"addClass":"removeClass"]("collapsed"),e(i).collapse(s)})}(window.jQuery),!function(e){"use strict";function r(){e(".dropdown-backdrop").remove(),e(t).each(function(){i(e(this)).removeClass("open")})}function i(t){var n=t.attr("data-target"),r;n||(n=t.attr("href"),n=n&&/#/.test(n)&&n.replace(/.*(?=#[^\s]*$)/,"")),r=n&&e(n);if(!r||!r.length)r=t.parent();return r}var t="[data-toggle=dropdown]",n=function(t){var n=e(t).on("click.dropdown.data-api",this.toggle);e("html").on("click.dropdown.data-api",function(){n.parent().removeClass("open")})};n.prototype={constructor:n,toggle:function(t){var n=e(this),s,o;if(n.is(".disabled, :disabled"))return;return s=i(n),o=s.hasClass("open"),r(),o||("ontouchstart"in document.documentElement&&e(' - diff --git a/wp-content/plugins/wp-security-scan/res/pages/tpl/box-available-backups.php b/wp-content/plugins/wp-security-scan/res/pages/tpl/box-available-backups.php deleted file mode 100644 index 2a871d4f..00000000 --- a/wp-content/plugins/wp-security-scan/res/pages/tpl/box-available-backups.php +++ /dev/null @@ -1,70 +0,0 @@ - - -No backups files found.

    '; - } - else { - echo '
    '; - echo ''; - echo '
    '; - } -?> - \ No newline at end of file diff --git a/wp-content/plugins/wp-security-scan/res/pages/tpl/box-banners.php b/wp-content/plugins/wp-security-scan/res/pages/tpl/box-banners.php deleted file mode 100644 index 38a23c65..00000000 --- a/wp-content/plugins/wp-security-scan/res/pages/tpl/box-banners.php +++ /dev/null @@ -1,9 +0,0 @@ - - -
    -
    - - - -
    -
    diff --git a/wp-content/plugins/wp-security-scan/res/pages/tpl/box-database-backup.php b/wp-content/plugins/wp-security-scan/res/pages/tpl/box-database-backup.php deleted file mode 100644 index 095211a6..00000000 --- a/wp-content/plugins/wp-security-scan/res/pages/tpl/box-database-backup.php +++ /dev/null @@ -1,57 +0,0 @@ - - - -
    -
    -

    back up your data.'); ?>

    -

    Wordpress

    -
    -
    - - - - ($fname = WsdUtil::backupDatabase())) { - echo '

    '; - echo '',__('Database successfully backed up!'),''; - echo '
    ',__('Download backup file'),': '; - echo '',$fname,''; - echo '

    '; - } - else { - echo '

    '; - echo __('The database could not be backed up!'); - echo '
    ',__("A possible error might be that you didn't set up writing permissions for the backups directory!"); - echo '

    '; - } - } - } -?> -
    -
    - - - -
    -
    - -'; - printf(__('Important: The backups directory MUST be writable in order to use this feature!') - ,WPS_PLUGIN_DIR.'res/backups'); - echo '

    '; -endif; ?> diff --git a/wp-content/plugins/wp-security-scan/res/pages/tpl/box-database-change-prefix.php b/wp-content/plugins/wp-security-scan/res/pages/tpl/box-database-change-prefix.php deleted file mode 100644 index 55b8078d..00000000 --- a/wp-content/plugins/wp-security-scan/res/pages/tpl/box-database-change-prefix.php +++ /dev/null @@ -1,253 +0,0 @@ - -This feature is not yet available for MultiSite.

    '; - return; -} -$wpsIsPostBack = ($_SERVER['REQUEST_METHOD'] == 'POST'); -if ($wpsIsPostBack) -{ - if(wpsIsMultisite()){ wp_die('

    This feature is not yet available for MultiSite.

    '); } -} -?> -('.__('Yes').')'; - } - else { $_canAlter = '('.__('No').')'; } - - if ($isWPConfigWritable) - { - $wpConfigFileinfo = '('.__('Yes').')'; - } - else { $wpConfigFileinfo = '('.__('No').')'; } -?> - -
    -

    -

    :

    - -
    - -'; - echo ''; - echo __('In order to alter the wp-config.php file we need the file function which seems to be blacklisted by your server administrator!'); - echo ''; - echo '

    '; - - return; -} - -//@ If we cannot load the page -if ( ! $showPage ) -{ - echo '

    '; - if (!$canAlter) { - echo ''; - echo __('The User used to access the database must have ALTER rights in order to perform this action!'); - echo '
    '; - } - if (!$isWPConfigWritable) { - echo ''; - echo __('The wp-config file MUST be writable!'); - echo ''; - } - echo '

    '; - - //!! Stop here, no need to load the rest of the page - return; -} -?> - -'; - echo ''; - echo __('It is a security risk to have your files writable! - Please make sure that after running this script, the wp-config.php file\'s permissions are set to 0644 or to a more restrictive one. See: http://codex.wordpress.org/Changing_File_Permissions for more information.'); - echo ''; - echo '

    '; - } - //@ If the user has too many rights - if (!empty($acx_dbRights['rightsTooMuch'])) { - echo '

    '; - echo ''. __("Your currently used User to access the Wordpress Database holds too many rights. We suggest that you limit his rights or to use another User with more limited rights instead, to increase your website's Security.").''; - echo '

    '; - } -?> - -'; - $e .= '
    '.__('The User used to access the database must have ALTER rights in order to perform this action!'); - $e .= '
    '.__('The wp-config file MUST be writable!'); - - wp_die($e); - } - - $wpdb = $GLOBALS['wpdb']; - if (empty($wpdb)) - { - wp_die(__('An internal error has occurred (empty $wpdb). Please inform the plug-in author about this error. Thank you!')); - } - - $new_prefix = $_POST['newPrefixInput']; - - // validate prefix - if(! preg_match('/^[a-zA-Z_][a-zA-Z0-9_]+$/', $new_prefix)){ - $acxInfoMessage .= sprintf('Invalid table name prefix: %s', htmlentities($new_prefix)); - $new_prefix = $old_prefix; - } - else - { - if (empty($acx_dbRights['rightsEnough'])) - { - $wsd_Message .= ''. __('The User which is used to access your Wordpress Database, hasn\'t enough rights (is missing the ALTER right) to alter the Table structure. - If the user has ALTER rights and the tool is still not working, please contact us for assistance!').''; - } - - if (strlen($new_prefix) < strlen($_POST['newPrefixInput'])){ - $acxInfoMessage .= __('You used some characters disallowed in Table names. The sanitized prefix will be used instead').': '.$new_prefix; - } - if ($new_prefix == $old_prefix) { - if (!empty($acxInfoMessage)) { $acxInfoMessage .= '
    '; } - $acxInfoMessage .= __('No change! Please select a different table prefix value.'); - } - else - { - // Get the list of tables to modify - $tables = WsdUtil::getTablesToAlter(); - if (empty($tables)) - { - if (!empty($acxInfoMessage)) { $acxInfoMessage .= '
    '; } - $acxInfoMessage .= __("Internal Error: We couldn't retrieve the list of tables from the database! Please inform the plug-in author about this error! Thank you!"); - } - else - { - $result = WsdUtil::renameTables($tables, $old_prefix, $new_prefix); - - // check for errors - if (!empty($result)) - { - if (!empty($acxInfoMessage)) { $acxInfoMessage .= '
    '; } - $acxInfoMessage .= ''.__('All tables have been successfully updated!').''; - - // try to rename the fields - $acxInfoMessage .= WsdUtil::renameDbFields($old_prefix, $new_prefix); - - if (0 < WsdUtil::updateWpConfigTablePrefix($wpConfigFile, $new_prefix)) - { - $acxInfoMessage .= '
    '.__('The wp-config file has been successfully updated!').''; - } - else { - $acxInfoMessage .= '
    '.__('The wp-config file could not be updated! You have to manually update the $table_prefix variable to the one you have specified').': '.$new_prefix; - } - }// End if tables successfully renamed - else { $acxInfoMessage .= '
    '.__('An error has occurred and the tables could not be updated!').''; } - }// End if there are tables to rename - }// End checks - } - }// End if (!empty($_POST['newPrefixInput'])) - }// End if postback - else { $new_prefix = $old_prefix; } - -if(empty($new_prefix)){ - $new_prefix = $old_prefix; -} -?> - - -
    -
    - -

    table prefix to something different.'), $new_prefix); ?>

    -

    _ (underscore).');?>

    - -
    -
    -
    - ',$acxInfoMessage,'

    '; } - if (!empty($wsd_Message)) { echo '

    ',$wsd_Message,'

    '; } - } - else { - if (!empty($wsd_Message)) { echo '

    ',$wsd_Message,'

    '; } - } - ?> -
    diff --git a/wp-content/plugins/wp-security-scan/res/pages/tpl/box-scan-results-file.php b/wp-content/plugins/wp-security-scan/res/pages/tpl/box-scan-results-file.php deleted file mode 100644 index 206d32f9..00000000 --- a/wp-content/plugins/wp-security-scan/res/pages/tpl/box-scan-results-file.php +++ /dev/null @@ -1,119 +0,0 @@ - - -'; - wp_nonce_field('wsdplugin_update_paths','wsdplugin_update_paths_field'); - echo ''; - echo ''; - echo ''; - echo ''; - echo ''; - echo ''; - echo ''; - echo ''; - echo ''; - echo ''; - echo ''; - foreach($acxFileList as $fileName => $v) - { - $filePath = $v['filePath']; - - if(false !== ($pos = stripos($filePath, 'readme'))){ - if(! is_file($filePath)){ - // safely ignore the readme file - continue; - } - } - - $p = WsdUtil::getFilePermissions($filePath); - $sp = $v['suggestedPermissions']; - - $cssClass = ((octdec($p) == octdec($sp)) ? 'success' : 'error'); - - echo ''; - echo ''; - echo ''; - echo ''; - //@ Current - if ($p > octdec('0')) { - echo ''; - } - else { echo ''; } - - //@ Suggested - if (file_exists($filePath)) - { - echo ''; - } - else - { - if (is_file($filePath)) { - echo ''; - } - elseif (is_dir($filePath)) { echo ''; } - else { - echo ''; - } - } - echo ''; - } - echo ''; - echo '
    ',__('Name'),'',__('Path'),'',__('Current permissions'),'',__('Suggested permissions'),'
    ',$fileName,'',(empty($filePath) ? 'Not Found' : WsdUtil::normalizePath($filePath)),'',$p,'',__('Not Found'),'',$sp,'06440755',$sp,'
    '; - - if(! WsdUtil::isWinOs()){ - echo '

    '; - //@@ Display action result - if ($acx_isPostBack && !empty($acx_message)){ - echo '

    '.$acx_message.'

    '; - } - if(wpsIsMainSite()){ - echo ''; - } - echo '
    '; - } - echo ''; - - echo '

    '; - echo __('Our suggested permissions are still secure but more permissive in order not to break some servers\' setups. - If your existent file permissions are more restrictive, ex: 0750 instead of the suggested 0755 then you have no reason to - change it to the suggested 0755 permissions.'); - echo '

    '; -} -?> \ No newline at end of file diff --git a/wp-content/plugins/wp-security-scan/res/pages/tpl/box-scan-results-wp.php b/wp-content/plugins/wp-security-scan/res/pages/tpl/box-scan-results-wp.php deleted file mode 100644 index b9df2316..00000000 --- a/wp-content/plugins/wp-security-scan/res/pages/tpl/box-scan-results-wp.php +++ /dev/null @@ -1,17 +0,0 @@ - - diff --git a/wp-content/plugins/wp-security-scan/res/pages/tpl/box-server-results.php b/wp-content/plugins/wp-security-scan/res/pages/tpl/box-server-results.php deleted file mode 100644 index 77a49d18..00000000 --- a/wp-content/plugins/wp-security-scan/res/pages/tpl/box-server-results.php +++ /dev/null @@ -1,3 +0,0 @@ - - - diff --git a/wp-content/plugins/wp-security-scan/res/pages/tpl/index.php b/wp-content/plugins/wp-security-scan/res/pages/tpl/index.php deleted file mode 100644 index fe0ab8ea..00000000 --- a/wp-content/plugins/wp-security-scan/res/pages/tpl/index.php +++ /dev/null @@ -1 +0,0 @@ - - -window.location.href = "admin.php?page='.WPS_PLUGIN_PREFIX.'wpscan";'; - return; - } - else - { - $isValidScan = WsdWpScanner::isValidScan($scanID); - if($isValidScan) - { - $scanInfo = WsdWpScanner::getScanInfo($scanID); - $scanStartDate = $scanInfo->scanStartDate; - $scanEndDate = $scanInfo->scanEndDate; - $scanFailed = $scanInfo->scanResult; - $failReason = $scanInfo->failReason; - $entries = WsdWpScanner::getFailedEntries($scanID); - $scanType = $scanInfo->scanType; - $h24 = 24 * 60 * 60; - $since = 0; - if($scanType == 0) { $since = strtotime($scanStartDate); } - elseif($scanType == 1){ $since = strtotime($scanStartDate) - $h24; } - elseif($scanType == 2){ $since = strtotime($scanStartDate) - 2*$h24; } - elseif($scanType == 3){ $since = strtotime($scanStartDate) - 3*$h24; } - elseif($scanType == 4){ $since = strtotime($scanStartDate) - 4*$h24; } - elseif($scanType == 5){ $since = strtotime($scanStartDate) - 5*$h24; } - elseif($scanType == 6){ $since = strtotime($scanStartDate) - 6*$h24; } - elseif($scanType == 7){ $since = strtotime($scanStartDate) - 7*$h24; } - elseif($scanType == 8){ $since = strtotime("-1 months") - $h24 - strtotime($scanStartDate); } - } - // not a valid scan - else { - $scanID = 0; - echo ''; - } - } -?> -fileNotFound){ - array_push($filesNotFound, $entry); - } - else { array_push($modifiedFiles, $entry); } - } -} -$numModified = count($modifiedFiles); -$num404 = count($filesNotFound); -?> -
    -
    -
    -

    -
    -
    -
    - - - - - - - - - - - - - - - - - - - - - -
    -

    - -
    -

    ()

    -
    - - - - - - - - - - - - - - -
    filePath;?>dateModified;?>
    - -

    - - - -
    -

    ()

    -
    - - - - - - - - - - - - -
    filePath;?>
    - -

    - - - -

    - - '. __("Invalid scan ID provided.",WpsSettings::TEXT_DOMAIN).'

    '; - endif; //#! $isValidScan - ?> -
    -
    -
    -
    \ No newline at end of file diff --git a/wp-content/plugins/wp-security-scan/res/pages/tpl/tpl-last-scans-list.php b/wp-content/plugins/wp-security-scan/res/pages/tpl/tpl-last-scans-list.php deleted file mode 100644 index ef7755c4..00000000 --- a/wp-content/plugins/wp-security-scan/res/pages/tpl/tpl-last-scans-list.php +++ /dev/null @@ -1,70 +0,0 @@ - - -There are no finished scans yet.

    '; - } - else { - if(!$showScanForm){ - echo '
    '; - echo (function_exists('wp_nonce_field')) ? wp_nonce_field('wss-wp-scan-nonce') : ''; - } - echo ''; - if(!$showScanForm){ - echo '
    '; - } - } -?> - - 0):?> -

    - -

    - - - \ No newline at end of file diff --git a/wp-content/plugins/wp-security-scan/res/pages/tpl/tpl-scan-done.php b/wp-content/plugins/wp-security-scan/res/pages/tpl/tpl-scan-done.php deleted file mode 100644 index 54eecd55..00000000 --- a/wp-content/plugins/wp-security-scan/res/pages/tpl/tpl-scan-done.php +++ /dev/null @@ -1,35 +0,0 @@ - - -scanId; - $scanStartDate = $scanInfo->scanStartDate; - $scanEndDate = $scanInfo->scanEndDate; - $scanFailed = ($scanInfo->scanResult == 0); - $scanType = $scanInfo->scanType; - - $h24 = 24 * 60 * 60; - $since = 0; - if($scanType == 0) { $since = strtotime($scanStartDate); } - elseif($scanType == 1){ $since = strtotime($scanStartDate) - $h24; } - elseif($scanType == 2){ $since = strtotime($scanStartDate) - 2*$h24; } - elseif($scanType == 3){ $since = strtotime($scanStartDate) - 3*$h24; } - elseif($scanType == 4){ $since = strtotime($scanStartDate) - 4*$h24; } - elseif($scanType == 5){ $since = strtotime($scanStartDate) - 5*$h24; } - elseif($scanType == 6){ $since = strtotime($scanStartDate) - 6*$h24; } - elseif($scanType == 7){ $since = strtotime($scanStartDate) - 7*$h24; } - elseif($scanType == 8){ $since = strtotime("-1 months") - $h24 - strtotime($scanStartDate); } -?> -

    Scan complete

    -
    -

    Scan ID:

    -

    Start date:

    -

    End date:

    -

    Type: Check for modified files since

    -

    Success:

    -Error: '.$scanInfo->failReason.'

    '; } -?> -

    View Report

    diff --git a/wp-content/plugins/wp-security-scan/res/pages/tpl/tpl-scan-none.php b/wp-content/plugins/wp-security-scan/res/pages/tpl/tpl-scan-none.php deleted file mode 100644 index fb526ad2..00000000 --- a/wp-content/plugins/wp-security-scan/res/pages/tpl/tpl-scan-none.php +++ /dev/null @@ -1,8 +0,0 @@ - - - -

    Scan State: None

    -
    -

    This tool will try to identify your WordPress version and it will check all files against the official released - version of WordPress to see if they were modified in the selected time interval.

    -

    Select the time interval to check if any of the WordPress core files were modified.

    diff --git a/wp-content/plugins/wp-security-scan/res/pages/tpl/tpl-scan-progress.php b/wp-content/plugins/wp-security-scan/res/pages/tpl/tpl-scan-progress.php deleted file mode 100644 index ba69dfef..00000000 --- a/wp-content/plugins/wp-security-scan/res/pages/tpl/tpl-scan-progress.php +++ /dev/null @@ -1,53 +0,0 @@ - - -root directory'; - } - elseif($progress == WsdWPScanSettings::SCAN_PROGRESS_ADMIN){ - $currentlyScanning = 'wp-admin directory'; - } - elseif($progress == WsdWPScanSettings::SCAN_PROGRESS_CONTENT){ - $currentlyScanning = 'wp-content directory'; - } - elseif($progress == WsdWPScanSettings::SCAN_PROGRESS_INCLUDES){ - $currentlyScanning = 'wp-includes directory'; - } -?> - - -

    Scan State: In Progress

    -
    - -

    - - - -

    -

    Scan ID:

    -

    Currently scanning:

    \ No newline at end of file diff --git a/wp-content/plugins/wp-security-scan/res/pages/tpl/tpl-scan-waiting.php b/wp-content/plugins/wp-security-scan/res/pages/tpl/tpl-scan-waiting.php deleted file mode 100644 index 236440bc..00000000 --- a/wp-content/plugins/wp-security-scan/res/pages/tpl/tpl-scan-waiting.php +++ /dev/null @@ -1,8 +0,0 @@ - - - -

    Scan State: Waiting

    -
    - -

    The scan will start in approximately 1 minute.

    -

    Scan ID:

    diff --git a/wp-content/plugins/wp-security-scan/res/pages/wp-scan.php b/wp-content/plugins/wp-security-scan/res/pages/wp-scan.php deleted file mode 100644 index ebbd76dc..00000000 --- a/wp-content/plugins/wp-security-scan/res/pages/wp-scan.php +++ /dev/null @@ -1,211 +0,0 @@ - -'', 'message' => '' */); - -$rm = strtoupper($_SERVER['REQUEST_METHOD']); -if('POST' == $rm) -{ - if (function_exists('wp_nonce_field')) { - check_admin_referer('wss-wp-scan-nonce'); - } - - $scanSettings = WsdWPScanSettings::getSettings(); - $scanProgress = $scanSettings['SCAN_PROGRESS']; - $scanState = $scanSettings['SCAN_STATE']; - $scanType = $scanSettings['SCAN_TYPE']; - $scanID = $scanSettings['SCAN_ID']; - - //#! Check if this is a request to delete scans - if(isset($_POST['deleteScan'])) - { - $scanID = intval($_POST['deleteScan']); - wssLog('Receiving delete scan command for scan ID: ',$scanID); - if(WsdWpScanner::isValidScan($scanID)) - { - if(!WsdWpScanner::deleteScan($scanID)){ - echo ''; - } - } - else { echo ''; } - } - //#! Delete all scans - elseif(isset($_POST['deleteAllScans'])){ - wssLog('Receiving command: delete all scans.'); - if(WsdWpScanner::deleteAllScans()){ - $eInfo['message'] = 'All scans have been deleted.'; - } - else { $eInfo['error'] = 'An error occurred while deleting the scans. Please try again in a few moments.'; } - } - //#! Normal scan registration request - else - { - // scanType - if(isset($_POST['scanType'])) - { - $type = intval($_POST['scanType']); - $eInfo['message'] = $type; - $scanSettings = WsdWPScanSettings::getSettings(); - $scanProgress = $scanSettings['SCAN_PROGRESS']; - $scanState = $scanSettings['SCAN_STATE']; - $scanType = $scanSettings['SCAN_TYPE']; - - $result = WsdWpScanner::registerScan($type); - if(-1 == $result){ - $eInfo['error'] = "A scan is already pending to start. You must wait for it to finish to register another one."; - $enableSubmit = false; - } - elseif(0 == $result){ - $eInfo['error'] = "A scan is already in progress. You must wait for it to finish to register another one."; - $enableSubmit = false; - } - elseif(1 == $result){ - $eInfo['error'] = "Invalid form. Please provide a valid scan type."; - } - elseif(2 == $result){ - $eInfo['error'] = "Internal Error: could not retrieve the ID for the last added scan."; - } - elseif(3 === $result){ - $eInfo['message'] = "Scan successfully registered. It should start in approximately 1 minute. You can come back later on to check on its status."; - $scanSettings = WsdWPScanSettings::getSettings(); - $scanProgress = $scanSettings['SCAN_PROGRESS']; - $scanState = $scanSettings['SCAN_STATE']; - $scanType = $scanSettings['SCAN_TYPE']; - $enableSubmit = false; - } - } - else { $eInfo['error'] = "Invalid form."; } - } -} -//#! GET -else { - $scanSettings = WsdWPScanSettings::getSettings(); - $scanProgress = $scanSettings['SCAN_PROGRESS']; - $scanState = $scanSettings['SCAN_STATE']; - $scanType = $scanSettings['SCAN_TYPE']; - $enableSubmit = (in_array($scanState, array(WsdWPScanSettings::SCAN_STATE_DONE, WsdWPScanSettings::SCAN_STATE_NONE)) ? true : false); -} - -//#! Whether or not to show the scan form -$showScanForm = !((isset($_GET) && !empty($_GET['scan']))); -?> - -
    -

    -
    - -
    -

    This tool helps you identify if, and what WordPress core files (depending on the version installed) have been modified in the specified time range.

    -
    - -
    - -
    - -
    - - '.$eInfo['error'].'

    '; } - elseif(isset($eInfo['message'])){ echo '

    '.$eInfo['message'].'

    '; } - ?> - -
    - - - - -
    - -
    - - $scanSettings['SCAN_ID'])); - } - elseif($scanState == WsdWPScanSettings::SCAN_STATE_DONE) - { - echo WsdUtil::loadTemplate('tpl-scan-done'); - } - elseif($scanState == WsdWPScanSettings::SCAN_STATE_IN_PROGRESS) - { - echo WsdUtil::loadTemplate('tpl-scan-progress', array('scanID'=>$scanSettings['SCAN_ID'])); - } - ?> -
    -
    - - - - - -
    - -
    - -
    -

    Previous Scans

    -
    - $showScanForm, 'scanState'=>$scanState)); ?> -
    -
    -
    - -
    -
    - - - \ No newline at end of file diff --git a/wp-content/plugins/wp-security-scan/screenshot-1.jpg b/wp-content/plugins/wp-security-scan/screenshot-1.jpg deleted file mode 100644 index 5d83dcf4..00000000 Binary files a/wp-content/plugins/wp-security-scan/screenshot-1.jpg and /dev/null differ diff --git a/wp-content/plugins/wp-security-scan/screenshot-2.jpg b/wp-content/plugins/wp-security-scan/screenshot-2.jpg deleted file mode 100644 index 7f31d4dd..00000000 Binary files a/wp-content/plugins/wp-security-scan/screenshot-2.jpg and /dev/null differ diff --git a/wp-content/plugins/wp-security-scan/screenshot-3.jpg b/wp-content/plugins/wp-security-scan/screenshot-3.jpg deleted file mode 100644 index 3d48c2b6..00000000 Binary files a/wp-content/plugins/wp-security-scan/screenshot-3.jpg and /dev/null differ diff --git a/wp-content/plugins/wp-security-scan/screenshot-4.jpg b/wp-content/plugins/wp-security-scan/screenshot-4.jpg deleted file mode 100644 index e9790540..00000000 Binary files a/wp-content/plugins/wp-security-scan/screenshot-4.jpg and /dev/null differ diff --git a/wp-content/plugins/wp-security-scan/screenshot-5.jpg b/wp-content/plugins/wp-security-scan/screenshot-5.jpg deleted file mode 100644 index 939267e8..00000000 Binary files a/wp-content/plugins/wp-security-scan/screenshot-5.jpg and /dev/null differ diff --git a/wp-content/plugins/wp-security-scan/wss-settings.php b/wp-content/plugins/wp-security-scan/wss-settings.php deleted file mode 100644 index 471a0512..00000000 --- a/wp-content/plugins/wp-security-scan/wss-settings.php +++ /dev/null @@ -1,144 +0,0 @@ - 'Today', - 1 => 'Yesterday', - 2 => '2 days ago', - 3 => '3 days ago', - 4 => '4 days ago', - 5 => '5 days ago', - 6 => '6 days ago', - 7 => '7 days ago', - 8 => 'Last month', - ); - - static $ignoreThemes = array('twentyten', 'twentyeleven', 'twentytwelve', 'twentythirteen'); - static $ignorePlugins = array('akismet', 'hello.php'); - - /** - * Sets the list of files to check for permissions - * @return array - */ - static function getScanFileList() - { - $_wpsPlugin_base_path = trailingslashit(ABSPATH); - $_wpsPluginWpConfigPath = WsdUtil::getWpConfigFilePath(); - return array( - //@@ Directories - 'root directory' => array( 'filePath' => $_wpsPlugin_base_path, 'suggestedPermissions' => '0755'), - 'wp-admin' => array( 'filePath' => $_wpsPlugin_base_path.'wp-admin', 'suggestedPermissions' => '0755'), - 'wp-content' => array( 'filePath' => $_wpsPlugin_base_path.'wp-content', 'suggestedPermissions' => '0755'), - 'wp-includes' => array( 'filePath' => $_wpsPlugin_base_path.'wp-includes', 'suggestedPermissions' => '0755'), - //@@ Files - '.htaccess' => array( 'filePath' => $_wpsPlugin_base_path.'.htaccess', 'suggestedPermissions' => '0644'), - 'readme.html' => array( 'filePath' => $_wpsPlugin_base_path.'readme.html', 'suggestedPermissions' => '0400'), - 'wp-config.php' => array( 'filePath' => $_wpsPluginWpConfigPath, 'suggestedPermissions' => '0644'), - 'wp-admin/index.php' => array( 'filePath' => $_wpsPlugin_base_path.'wp-admin/index.php', 'suggestedPermissions' => '0644'), - 'wp-admin/.htaccess' => array( 'filePath' => $_wpsPlugin_base_path.'wp-admin/.htaccess', 'suggestedPermissions' => '0644'), - ); - } - - /** - * @TODO: Always keep in sync with methods from WsdSecurity class... - * @return array - */ - static function getSettingsList() - { - return array( - array('name' => 'fix_hideWpVersion', - 'text' => 'Hide WordPress version for all users but administrators'), - array('name' => 'fix_removeWpMetaGeneratorsFrontend', - 'text' => 'Remove various meta tags generators from the blog\'s head tag for non-administrators'), - array('name' => 'fix_removeReallySimpleDiscovery', - 'text' => 'Remove Really Simple Discovery meta tags from front-end'), - array('name' => 'fix_removeWindowsLiveWriter', - 'text' => 'Remove Windows Live Writer meta tags from front-end'), - array('name' => 'fix_disableErrorReporting', - 'text' => 'Disable error reporting (php + db) for all but administrators'), - array('name' => 'fix_removeCoreUpdateNotification', - 'text' => 'Remove core update notifications from back-end for all but administrators'), - array('name' => 'fix_removePluginUpdateNotifications', - 'text' => 'Remove plug-ins update notifications from back-end'), - array('name' => 'fix_removeThemeUpdateNotifications', - 'text' => 'Remove themes update notifications from back-end'), - array('name' => 'fix_removeLoginErrorNotificationsFrontEnd', - 'text' => 'Remove login error notifications from front-end'), - array('name' => 'fix_hideAdminNotifications', - 'text' => 'Hide admin notifications for non admins'), - array('name' => 'fix_preventDirectoryListing', - 'text' => 'Try to create the index.php file in the wp-content, wp-content/plugins, wp-content/themes and wp-content/uploads directories to prevent directory listing'), - array('name' => 'fix_removeWpVersionFromLinks', - 'text' => 'Remove the version parameter from urls'), - array('name' => 'fix_emptyReadmeFileFromRoot', - 'text' => 'Empty the content of the readme.html file from the root directory'), - ); - } - - static function getJsonRepoUrl(){ - $dirPath = WPS_PLUGIN_DIR.'res/json/fscan/'; - if(! is_dir($dirPath)){ - return null; - } - return $dirPath; - } -}