Plugin Directory

Changeset 2636555


Ignore:
Timestamp:
11/28/2021 06:05:47 PM (4 years ago)
Author:
wpsecuredcom
Message:

Adding version ${VERSION} of my plugin

Location:
secured-wp
Files:
422 added
3 deleted
34 edited
25 copied

Legend:

Unmodified
Added
Removed
  • secured-wp/tags/1.7/classes/Controllers/LoginCheck.php

    r2577925 r2636555  
    1414use WPSEC\Helpers\{
    1515    NotifyAdmin,
    16     OutOfBondEmail,
     16    OutOfBandEmail,
    1717};
    1818use WPSEC\Controllers\{
     
    3737         * Checks the user login credentials
    3838         *
    39          * TODO: change the loging in user check - set proper priorities
     39         * TODO: change the logging in user check - set proper priorities
    4040         *
    4141         * 1. Checks if user is locked
     
    5555        public static function check( $user, $username, $password ) {
    5656
     57            /**
     58             * If neither of modules is enabled - return the user
     59             */
    5760            if ( (bool) \WPSEC\Controllers\Modules\LoginAttempts::getGlobalSettingsValue()
    5861                &&
     
    187190         * @return void
    188191         *
    189          * @since
     192         * @since $VERSION
    190193         */
    191194        public static function loginValidateOob() {
     
    207210        public static function setRememberMe() {
    208211
    209             if ( isset( $_POST['rememberme'] ) && ! empty( $_POST['rememberme'] ) ) {
     212            if ( isset( $_POST['rememberme'] ) && ! empty( $_POST['rememberme'] ) ) { // @codingStandardsIgnoreLine - Nonce check is not needed
    210213                RememberMe::setRememberMe( User::getUser()->ID );
    211214                User::setLoggedInDevice( RememberMe::getDevice() );
     
    214217
    215218        /**
    216          * Checks Out of bond email link and logging the user if passed
     219         * Checks Out of band email link and logging the user if passed
    217220         *
    218221         * @param bool $secondPass - first pass comes from e-mail (link), second pass comes from WP form itself.
     
    240243                            $wpsOtp = (string) \sanitize_text_field( \wp_unslash( $params['wps_otp'] ) );
    241244
    242                             $nonceName = OutOfBondEmail::getNonceName();
     245                            $nonceName = OutOfBandEmail::getNonceName();
    243246
    244247                            if ( isset( $params[ $nonceName ] ) && ! empty( $params[ $nonceName ] ) ) {
    245                                 if ( ! \wp_verify_nonce( \sanitize_text_field( \wp_unslash( $params[ $nonceName ] ) ), OutOfBondEmail::getNonceNamePrefix() . $userId ) ) {
     248                                if ( ! \wp_verify_nonce( \sanitize_text_field( \wp_unslash( $params[ $nonceName ] ) ), OutOfBandEmail::getNonceNamePrefix() . $userId ) ) {
    246249                                    exit();
    247250                                }
    248251
    249252                                // check transient.
    250                                 $dataTimeout = \get_option( '_transient_timeout_' . OutOfBondEmail::getTransientPrefix() . ( (string) $userId ) );
     253                                $dataTimeout = \get_option( '_transient_timeout_' . OutOfBandEmail::getTransientPrefix() . ( (string) $userId ) );
    251254                                if ( $dataTimeout > time() ) {
    252                                     if ( OutOfBondEmail::validateUserOOB( $userId, $wpsOtp ) ) {
     255                                    if ( OutOfBandEmail::validateUserOOB( $userId, $wpsOtp ) ) {
    253256
    254257                                        if ( ! $secondPass ) {
     
    257260                                        }
    258261                                        \wp_clear_auth_cookie();
    259                                         OutOfBondEmail::deleteTransient( $userId );
     262                                        OutOfBandEmail::deleteTransient( $userId );
    260263                                        \wp_set_current_user( $userId );
    261264                                        \wp_set_auth_cookie( $userId );
  • secured-wp/tags/1.7/classes/Controllers/Modules/Login.php

    r2576070 r2636555  
    7979            \add_action( 'plugins_loaded', [ __CLASS__, 'pluginsLoaded' ], 9999 );
    8080            \add_action( 'wp_loaded', [ __CLASS__, 'wpLoaded' ] );
     81            \add_action( 'wp_redirect', [ __CLASS__, 'wpRedirect' ], 10, 2 );
    8182            \add_action( 'setup_theme', [ __CLASS__, 'setupTheme' ], 1 );
    8283
     
    567568
    568569        /**
    569          * Check the current url and changes it if necessary
    570          *
    571          * @since 1.0.0
    572          *
    573          * @param string $url - the url of the site.
    574          * @param mixed  $scheme - the URL scheme.
    575          *
    576          * @return string
    577          */
    578         public static function filterWpLoginPhp( $url, $scheme = null ): string {
    579 
    580             if ( false !== strpos( $url, 'wp-login.php?action=postpass' ) ) {
     570         * Called on wp_redirect action. Checks the URL string, and filters it accordingly if wp-login.php is presented (substitute it with the new slug)
     571         *
     572         * @param string  $url - The URL to which WP is trying to redirect to.
     573         * @param integer $status - Number code of the status.
     574         *
     575         * @return string
     576         *
     577         * @since 1.6
     578         */
     579        public static function wpRedirect( string $url, int $status ): string {
     580
     581            if ( strpos( $url, 'https://wordpress.com/wp-login.php' ) !== false ) {
    581582                return $url;
    582583            }
    583584
    584             if ( false !== strpos( $url, 'wp-login.php' ) && false === strpos( (string) \wp_get_referer(), 'wp-login.php' ) ) {
    585 
    586                 if ( \is_ssl() ) {
    587 
    588                     $scheme = 'https';
    589 
    590                 }
    591 
    592                 $args = explode( '?', $url );
    593 
    594                 if ( isset( $args[1] ) ) {
    595 
    596                     parse_str( $args[1], $args );
    597 
    598                     if ( isset( $args['login'] ) ) {
    599                         $args['login'] = rawurlencode( $args['login'] );
    600                     }
    601 
    602                     $url = \add_query_arg( $args, self::newLoginUrl( $scheme ) );
    603 
    604                 } else {
    605 
    606                     $url = self::newLoginUrl( $scheme );
    607 
    608                 }
    609             }
    610 
    611             return $url;
    612 
     585            return self::filterWpLoginPhp( $url );
    613586        }
    614587
     
    761734
    762735        /**
     736         * Checks the current url and changes it if necessary
     737         *
     738         * @since 1.0.0
     739         *
     740         * @param string $url - the url of the site.
     741         * @param mixed  $scheme - the URL scheme.
     742         *
     743         * @return string
     744         */
     745        private static function filterWpLoginPhp( $url, $scheme = null ): string {
     746
     747            if ( false !== strpos( $url, 'wp-login.php?action=postpass' ) ) {
     748                return $url;
     749            }
     750
     751            if ( false !== strpos( $url, 'wp-login.php' ) && false === strpos( (string) \wp_get_referer(), 'wp-login.php' ) ) {
     752
     753                if ( \is_ssl() ) {
     754
     755                    $scheme = 'https';
     756
     757                }
     758
     759                $args = explode( '?', $url );
     760
     761                if ( isset( $args[1] ) ) {
     762
     763                    parse_str( $args[1], $args );
     764
     765                    if ( isset( $args['login'] ) ) {
     766                        $args['login'] = rawurlencode( $args['login'] );
     767                    }
     768
     769                    $url = \add_query_arg( $args, self::newLoginUrl( $scheme ) );
     770
     771                } else {
     772
     773                    $url = self::newLoginUrl( $scheme );
     774
     775                }
     776            }
     777
     778            return $url;
     779        }
     780
     781        /**
    763782         * Returns the wpLogin status
    764783         *
  • secured-wp/tags/1.7/classes/Controllers/Modules/RememberMe.php

    r2576070 r2636555  
    247247
    248248            \delete_transient(
    249                 self::$transientPrefix . md5( $device ) . '_' . $userId,
     249                self::$transientPrefix . md5( $device ) . '_' . $userId
    250250            );
    251251        }
  • secured-wp/tags/1.7/classes/Controllers/Modules/XMLRPCprevents.php

    r2576070 r2636555  
    1313
    1414use WPSEC\Helpers\WPHelper;
    15 use WPSEC\Validators\Validator;
    1615
    1716defined( 'ABSPATH' ) || exit; // Exit if accessed directly.
  • secured-wp/tags/1.7/classes/Controllers/User.php

    r2579465 r2636555  
    616616         * @return string
    617617         *
    618          * @since
     618         * @since 1.7
    619619         */
    620620        public static function getStatus( $user = null ): string {
  • secured-wp/tags/1.7/classes/Secured.php

    r2579465 r2636555  
    2727};
    2828use WPSEC\Validators\Validator;
     29use WPSEC\Views\UserProfile;
    2930
    3031if ( ! class_exists( 'WPSEC\Secured' ) ) {
     
    6162         * @since 1.0.0
    6263         *
    63          * @param array $links - Gloabal links array.
     64         * @param array $links - Global links array.
    6465         *
    6566         * @return array
     
    9192                /* translators: %1$s: PHP version */
    9293                    \esc_html__( 'You need to update your PHP version to %1s.', 'secured-wp' ),
    93                     WPSEC_REQUIRED_PHP_VERSION // @codingStandardsIgnoreLine - that is defined constatnt no need to escape it
     94                    WPSEC_REQUIRED_PHP_VERSION // @codingStandardsIgnoreLine - that is defined constant no need to escape it
    9495                );
    9596                ?>
     
    112113                /* translators: %1$s: WP version */
    113114                    \esc_html__( 'You need to update your WP version to %1s.', 'secured-wp' ),
    114                 WPSEC_REQUIRED_WP_VERSION // @codingStandardsIgnoreLine - that is defined constatnt no need to escape it
     115                    WPSEC_REQUIRED_WP_VERSION // @codingStandardsIgnoreLine - that is defined constant no need to escape it
    115116                );
    116117                ?>
     
    170171         * Returns the status of delete data upon uninstall
    171172         *
    172          * @since 1.0.0
    173          *
    174173         * @param mixed $blogId - WP blog ID.
    175174         *
    176175         * @return mixed
     176         *
     177         * @since 1.0.0
    177178         */
    178179        public static function isDeleteDataEnabled( $blogId = '' ) {
     
    220221
    221222        /**
     223         * Shows the content for user settings when short code is used
     224         *
     225         * @return void - the parsed HTML.
     226         *
     227         * @since 1.6
     228         */
     229        public static function settingsShortCode() {
     230
     231            if ( User::isCurrentlyLogged() ) {
     232                $user = User::getUser();
     233                ob_start();
     234                UserProfile::userEditProfile( $user );
     235                $content = ob_get_clean();
     236                echo $content;  // @codingStandardsIgnoreLine - All output must be escaped warning
     237            } else {
     238                ?>
     239                <h2><?php echo \esc_html__( 'You must be logged in to see this content', 'secured-wp' ); ?></h2>
     240                <?php
     241            }
     242        }
     243
     244        /**
    222245         * Inits all the hooks the plugin will use
    223246         *
    224          * @since 1.0.0
    225          *
    226          * @return void
     247         * @return void
     248         *
     249         * @since 1.0.0
    227250         */
    228251        private static function initHooks() {
     
    237260             */
    238261            \add_action( 'login_form_confirm_oob', [ 'WPSEC\\Controllers\\LoginCheck', 'loginValidateOob' ], 1 );
     262
     263            /**
     264             * Adds shortcode - that gives the ability to create our own page with user settings
     265             */
     266            \add_shortcode( 'wps_custom_settings', [ __CLASS__, 'settingsShortCode' ] );
    239267
    240268            /**
     
    276304                 * Adds ajax request for sending the OOB
    277305                 */
    278                 \add_action( 'wp_ajax_nopriv_send_oob', [ 'WPSEC\\Helpers\\OutOfBondEmail', 'sendOOBEmail' ] );
    279                 \add_action( 'wp_ajax_send_oob', [ 'WPSEC\\Helpers\\OutOfBondEmail', 'sendOOBEmail' ] );
     306                \add_action( 'wp_ajax_nopriv_send_oob', [ 'WPSEC\\Helpers\\OutOfBandEmail', 'sendOOBEmail' ] );
     307                \add_action( 'wp_ajax_send_oob', [ 'WPSEC\\Helpers\\OutOfBandEmail', 'sendOOBEmail' ] );
    280308            }
    281309
     
    308336            /**
    309337             * If user is logged in and there is woocommerce installed and the method is enabled,
    310              * we gona need the AJAX methods available.
     338             * we gonna need the AJAX methods available.
    311339             */
    312340            if ( User::isCurrentlyLogged() ) {
    313                 if ( class_exists( 'WooCommerce' ) ) {
    314                     if ( ! (bool) \WPSEC\Controllers\Modules\TwoFASettings::getGlobalSettingsValue() ) {
    315                         // AJAX request for the user - do we need this globally for the Admin Part of the WP ?.
    316                         AjaxRequests::initAdmin();
    317                     }
     341                // if ( class_exists( 'WooCommerce' ) ) {
     342                if ( ! (bool) \WPSEC\Controllers\Modules\TwoFASettings::getGlobalSettingsValue() ) {
     343                    // AJAX request for the user - do we need this globally for the Admin Part of the WP ?.
     344                    AjaxRequests::initAdmin();
    318345                }
    319             }
    320         }
    321 
    322         /**
    323          * Conditionally add assets only when they are necessary
    324          *
    325          * @since 1.0.0
    326          *
    327          * @return void
     346                // }
     347            }
     348        }
     349
     350        /**
     351         * Conditionally adds assets only when they are necessary
     352         *
     353         * @return void
     354         *
     355         * @since 1.0.0
    328356         */
    329357        private static function addAssets() {
  • secured-wp/tags/1.7/classes/Views/LoginForms.php

    r2578321 r2636555  
    1212namespace WPSEC\Views;
    1313
     14use WPSEC\Helpers\TOTPHelper;
    1415use WPSEC\{
    1516    Controllers\User,
    1617    Controllers\Modules\TwoFASettings,
    17     Helpers\OutOfBondEmail
     18    Helpers\OutOfBandEmail
    1819};
    19 use OTPHP\TOTP;
    2020
    2121defined( 'ABSPATH' ) || exit; // Exit if accessed directly.
     
    107107            if ( ! User::isTotpUserEnabled() ) {
    108108                echo \esc_html( \get_bloginfo( 'name' ) );
    109 
    110                 $otp = TOTP::create( User::getUserTotp() );
    111 
    112                 $otp->setLabel(
    113                     \get_bloginfo( 'name' )
    114                 );
    115                 $grCodeUri = $otp->getQrCodeUri(
    116                     'https://api.qrserver.com/v1/create-qr-code/?data=[DATA]&size=200x200&ecc=M',
    117                     '[DATA]'
    118                 );
    119109                ?>
    120                 <div style='width:100%;margin: 0 auto; text-align:center;'><img src='<?php echo \esc_attr( $grCodeUri ); ?>'></div>
     110                <div style='width:100%;margin: 0 auto; text-align:center;'><img src='<?php echo \esc_attr( TOTPHelper::generateQRSVGData() ); ?>' width="100%"></div>
    121111                <?php
    122112                echo \esc_html__( 'Scan above with your favorite Authenticator Application and enter the code below or add the following code:', 'secured-wp' );
    123                 echo '<div><strong>' . \esc_html( $otp->getSecret() ) . '</strong></div>';
     113                echo '<div><strong>' . \esc_html( User::getUserTotp() ) . '</strong></div>';
    124114            } else {
    125115                echo \esc_html__( 'Open the Authenticator Application on your phone and enter the code for ' . \get_bloginfo( 'name' ), 'secured-wp' );
     
    198188                <input type="hidden" name="wps_otp" id="wps_otp" value="<?php echo \esc_attr( \wp_unslash( $_GET['wps_otp'] ) ); ?>" />
    199189                <input type="hidden" name="user_id" id="wps_otp" value="<?php echo \esc_attr( \wp_unslash( $_GET['user_id'] ) ); ?>" />
    200             <?php \wp_nonce_field( OutOfBondEmail::getNonceNamePrefix() . \wp_unslash( $_GET['user_id'] ), OutOfBondEmail::getNonceName() ); ?>
     190            <?php \wp_nonce_field( OutOfBandEmail::getNonceNamePrefix() . \wp_unslash( $_GET['user_id'] ), OutOfBandEmail::getNonceName() ); ?>
    201191            <div>
    202192                <p>
     
    271261
    272262        /**
    273          * Adds Out of bond link to the login form
     263         * Adds Out of Band link to the login form
    274264         *
    275265         * @since 1.0.0
     
    284274                ?>
    285275            <div style="clear: both;" id="wsc-oob-wrapper">
    286                 <a href="#" id="send-oob-mail"><?php echo \esc_html__( 'Send me out of bond email instead', 'secured-wp' ); ?></a>
     276                <a href="#" id="send-oob-mail"><?php echo \esc_html__( 'Send me out of band email instead', 'secured-wp' ); ?></a>
    287277            </div>
    288278            <script>
  • secured-wp/tags/1.7/classes/Views/SettingsTabs.php

    r2576070 r2636555  
    240240                    </tr>
    241241                    <tr>
    242                         <th scope="row"><?php echo \esc_html__( 'Out of bond e-mail ', 'secured-wp' ); ?></th>
     242                        <th scope="row"><?php echo \esc_html__( 'Out of band e-mail ', 'secured-wp' ); ?></th>
    243243                        <td>
    244244                            <label for="<?php echo \esc_attr( WPSEC_PLUGIN_SECURED_2FA_OOB_VAR_NAME ); ?>">
  • secured-wp/tags/1.7/classes/Views/UserProfile.php

    r2579465 r2636555  
    1414defined( 'ABSPATH' ) || exit; // Exit if accessed directly.
    1515
    16 use OTPHP\TOTP;
    1716use WPSEC\Controllers\{
    1817    User,
    1918    Modules\RememberMe,
    2019};
     20use WPSEC\Helpers\TOTPHelper;
    2121
    2222if ( ! class_exists( 'WPSEC\Views\UserProfile' ) ) {
     
    132132
    133133                </table>
    134                 <div class="tablenav">
     134                <div class="tablenav" style="overflow:hidden;">
    135135                    <div class="alignright">
    136136                    <?php
    137                     \submit_button(
    138                         __( 'Remove all logged in devices', 'secured-wp' ),
    139                         'delete',
    140                         'remove-all-logged-devices',
    141                         false
    142                     );
     137                    if ( function_exists( 'submit_button' ) ) {
     138                        \submit_button(
     139                            __( 'Remove all logged in devices', 'secured-wp' ),
     140                            'delete',
     141                            'remove-all-logged-devices',
     142                            false
     143                        );
     144                    } else {
     145                        ?>
     146                    <input type="submit" name="remove-all-logged-devices" id="remove-all-logged-devices" class="button delete" value="Remove all logged in devices">
     147                        <?php
     148                        self::deleteQRCodeJS();
     149                    }
    143150                    ?>
    144151                    </div>
    145152                </div>
    146                 <hr>
     153                <hr style="clear:both; margin-top:5px;">
    147154                <?php
    148155                if ( \current_user_can( 'edit_user', User::getUser()->ID ) && ! (bool) User::isTwoFaUserExcluded() ) {
     
    166173                ?>
    167174            <h3><?php echo \esc_html__( 'QR code for the TOTP 2FA login', 'secured-wp' ); ?></h3>
    168                 <?php
    169                 $otp = TOTP::create( User::getUserTotp() );
    170 
    171                 $otp->setLabel(
    172                     \get_bloginfo( 'name' )
    173                 );
    174                 $grCodeUri = $otp->getQrCodeUri(
    175                     'https://api.qrserver.com/v1/create-qr-code/?data=[DATA]&size=200x200&ecc=M',
    176                     '[DATA]'
    177                 );
    178                 ?>
    179             <div style='width:100%;margin: 0 auto; text-align:center;'><img src='<?php echo \esc_attr( $grCodeUri ); ?>'></div>
     175
     176            <div style='width:100%;margin: 0 auto; text-align:center;'><img src='<?php echo \esc_attr( TOTPHelper::generateQRSVGData() ); ?>'></div>
    180177            <div><?php echo \esc_html__( 'Or use the following key, by entering it directly in you preferable authentication application:', 'secured-wp' ); ?></div>
    181178            <div><strong><?php echo \esc_html( $otp->getSecret() ); ?></strong></div>
    182             <div class="tablenav">
     179            <div class="tablenav" style="overflow:hidden;">
    183180                <div class="alignleft">
    184181                <?php
     
    205202                </div>
    206203            </div>
     204            <hr style="clear:both; margin-top:5px;">
    207205                <?php
    208206            }
     
    316314            ?>
    317315        <script>
    318             ( function( jQuery ) {
    319                 jQuery('.alignleft').on('click', '#regenerate-qr-code', function(e) {
    320                     e.preventDefault();
    321                     var ajaxurl = "<?php echo \esc_url( admin_url( 'admin-ajax.php' ) ); ?>"
    322                     var deleteData = {
    323                         'action': 'wps_delete_qr',
    324                         'user': '<?php echo \esc_attr( User::getUser()->ID ); ?>',
    325                         'nonce': '<?php echo \esc_attr( \wp_create_nonce( 'wp-secured-wps_delete_qr-ajax-nonce' ) ); ?>',
    326                     };
    327 
    328                     let that = this;
    329 
    330                     jQuery.ajax({
    331                         type: "post",
    332                         dataType: "json",
    333                         url: ajaxurl,
    334                         data: deleteData,
    335                         success: function( msg ) {
    336                             if ( 'success' == msg['result'] ) {
    337                                 location.reload(); ;
    338                             }
    339                         }
    340                     });
    341                 });
    342             }( jQuery ) );
     316            var qrRegenerate = document.getElementById('regenerate-qr-code');
     317            qrRegenerate.addEventListener("click", function(e) {
     318                e.preventDefault();
     319                var request = new XMLHttpRequest();
     320
     321                request.open('POST', '<?php echo \esc_url( \admin_url( 'admin-ajax.php' ) ); ?>', true);
     322                request.setRequestHeader('Content-Type', 'application/x-www-form-urlencoded;');
     323                request.responseType = 'json';
     324                request.onload = function () {
     325                    if (this.status >= 200 && this.status < 400) {
     326                        location.reload();
     327                    } else {
     328                        // If fail
     329                        console.log(this.response);
     330                    }
     331                };
     332                request.onerror = function() {
     333                    console.log('Connection error');
     334                };
     335
     336                var deleteData = {
     337                    "action": "wps_delete_qr",
     338                    "user": "<?php echo \esc_attr( User::getUser()->ID ); ?>",
     339                    "nonce": "<?php echo \esc_attr( \wp_create_nonce( 'wp-secured-wps_delete_qr-ajax-nonce' ) ); ?>",
     340                };
     341
     342                request.send("action=wps_delete_qr&user=<?php echo \esc_attr( User::getUser()->ID ); ?>&nonce=<?php echo \esc_attr( \wp_create_nonce( 'wp-secured-wps_delete_qr-ajax-nonce' ) ); ?>");
     343            }, false);
     344
    343345        </script>
    344346            <?php
  • secured-wp/tags/1.7/classes/Views/UsersList.php

    r2578323 r2636555  
    5757         * @var string
    5858         *
    59          * @since
     59         * @since 1.7
    6060         */
    6161        private static $changeLockedBulkActionName = 'change-to-locked';
     
    6666         * @var string
    6767         *
    68          * @since
     68         * @since 1.7
    6969         */
    7070        private static $changeUnLockedBulkActionName = 'change-to-unlocked';
     
    7575         * @var string
    7676         *
    77          * @since
     77         * @since 1.7
    7878         */
    7979        private static $changeExcludeTwoFaBulkActionName = 'exclude-2fa';
     
    8484         * @var string
    8585         *
    86          * @since
     86         * @since 1.7
    8787         */
    8888        private static $changeIncludeTwoFaBulkActionName = 'include-2fa';
     
    127127            }
    128128
     129            // wpmu_users_columns
     130            // manage_users - network_sortable_columns
     131
    129132            /**
    130133             * Show logged in column
     
    136139            if ( WPHelper::isMultisite() ) {
    137140                \add_filter( 'wpmu_users_columns', [ __CLASS__, 'addUsersLoggedColumn' ] );
     141                \add_filter( 'manage_users-network_sortable_columns', [ __CLASS__, 'addUsersLoggedColumn' ] );
    138142            }
    139143
  • secured-wp/tags/1.7/constants.php

    r2579464 r2636555  
    1414}
    1515
    16 define( 'WPSEC_REQUIRED_PHP_VERSION', '7.2' );
     16define( 'WPSEC_REQUIRED_PHP_VERSION', '7.3' );
    1717define( 'WPSEC_REQUIRED_WP_VERSION', '5.0' );
    18 define( 'WPSEC_PLUGIN_SECURED_VERSION', '1.5' );
     18define( 'WPSEC_PLUGIN_SECURED_VERSION', '1.7' );
    1919define( 'WPSEC_PLUGIN_SECURED_NAME', 'Secured WP' );
    2020define( 'WPSEC_PLUGIN_SECURED_SLUG', 'secured-wp' );
  • secured-wp/tags/1.7/languages/secured-wp.pot

    r2577909 r2636555  
    11# Copyright (C) 2021 wp-secured
    2 # This file is distributed under the same license as the Secured WP plugin.
     2# This file is distributed under the GPL-2.0+.
    33msgid ""
    44msgstr ""
    5 "Project-Id-Version: Secured WP 1.1\n"
     5"Project-Id-Version: Secured WP 1.6\n"
    66"Report-Msgid-Bugs-To: https://wordpress.org/support/plugin/secured-wp\n"
    77"Last-Translator: FULL NAME <EMAIL@ADDRESS>\n"
     
    1010"Content-Type: text/plain; charset=UTF-8\n"
    1111"Content-Transfer-Encoding: 8bit\n"
    12 "POT-Creation-Date: 2021-08-04T14:05:08+03:00\n"
     12"POT-Creation-Date: 2021-08-15T09:21:29+00:00\n"
    1313"PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n"
    14 "X-Generator: WP-CLI 2.4.0\n"
    15 "X-Domain: wp-secured\n"
     14"X-Generator: WP-CLI 2.5.0\n"
     15"X-Domain: secured-wp\n"
    1616
    1717#. Plugin Name of the plugin
     
    3131msgid "wp-secured"
    3232msgstr ""
     33
     34#: classes/Controllers/LoginCheck.php:78
     35msgid "<strong>Error</strong>: Too soon."
     36msgstr ""
     37
     38#: classes/Controllers/LoginCheck.php:102
     39msgid "<strong>Error</strong>: Too many attempts."
     40msgstr ""
     41
     42#: classes/Controllers/LoginCheck.php:174
     43msgid "Invalid code provided"
     44msgstr ""
     45
     46#: classes/Controllers/Modules/Login.php:396
     47msgid "This feature is not enabled."
     48msgstr ""
     49
     50#: classes/Controllers/Modules/Login.php:447
     51msgid "Nothing to see here"
     52msgstr ""
     53
     54#: classes/Controllers/Modules/Login.php:682
     55msgid "Login"
     56msgstr ""
     57
     58#: classes/Controllers/Modules/Login.php:699
     59msgid "New login slug"
     60msgstr ""
     61
     62#: classes/Controllers/Modules/Login.php:703
     63msgid "Redirect original login"
     64msgstr ""
     65
     66#: classes/Controllers/Modules/Login.php:759
     67msgid "Hides the standard wp-login.php with your personal slug of choice. Redirects the original login to slug of your choice"
     68msgstr ""
     69
     70#: classes/Controllers/Modules/LoginAttempts.php:235
     71msgid "Login attempts"
     72msgstr ""
     73
     74#: classes/Controllers/Modules/LoginAttempts.php:252
     75#: classes/Views/SettingsTabs.php:119
     76msgid "Login Attempts"
     77msgstr ""
     78
     79#: classes/Controllers/Modules/LoginAttempts.php:256
     80#: classes/Controllers/Modules/RememberMe.php:351
     81#: classes/Views/SettingsTabs.php:127
     82msgid "Lock time"
     83msgstr ""
     84
     85#: classes/Controllers/Modules/LoginAttempts.php:257
     86msgid " mins."
     87msgstr ""
     88
     89#: classes/Controllers/Modules/LoginAttempts.php:294
     90msgid "Counts incorect login attempts and locks the user - use standard user menu to check locked users."
     91msgstr ""
     92
     93#: classes/Controllers/Modules/RememberMe.php:334
     94msgid "Remember Devices"
     95msgstr ""
     96
     97#: classes/Controllers/Modules/RememberMe.php:352
     98msgid " days."
     99msgstr ""
     100
     101#: classes/Controllers/Modules/RememberMe.php:405
     102msgid "When enabled, if user checks remember me on login, the device will be stored and the user wont be asked for credentials for the given amount of time."
     103msgstr ""
     104
     105#: classes/Controllers/Modules/TwoFASettings.php:189
     106msgid "2FA settings"
     107msgstr ""
     108
     109#: classes/Controllers/Modules/TwoFASettings.php:206
     110msgid "TOTP enabled"
     111msgstr ""
     112
     113#: classes/Controllers/Modules/TwoFASettings.php:207
     114#: classes/Controllers/Modules/TwoFASettings.php:211
     115#: classes/Helpers/Information/ModuleInformation.php:49
     116msgid "true"
     117msgstr ""
     118
     119#: classes/Controllers/Modules/TwoFASettings.php:207
     120#: classes/Controllers/Modules/TwoFASettings.php:211
     121#: classes/Helpers/Information/ModuleInformation.php:49
     122msgid "false"
     123msgstr ""
     124
     125#: classes/Controllers/Modules/TwoFASettings.php:210
     126msgid "OOB enabled"
     127msgstr ""
     128
     129#: classes/Controllers/Modules/TwoFASettings.php:266
     130msgid "Enables 2FA. Next time, when user logins s/he will be asked to add the site to Authenticator application of their choice, and from now on they must provide code from that App in order to login."
     131msgstr ""
     132
     133#: classes/Controllers/Modules/XMLRPCprevents.php:62
     134msgid "XML-RPC settings"
     135msgstr ""
     136
     137#: classes/Controllers/Modules/XMLRPCprevents.php:108
     138msgid "Disables XML-RPC. By default WordPress has that enabled - this is potentially security risk - that will disable XML-RPC on your site completely"
     139msgstr ""
     140
     141#: classes/Controllers/User.php:622
     142msgid "2FA enabled: YES"
     143msgstr ""
     144
     145#: classes/Controllers/User.php:623
     146msgid "TOTP enabled: NO"
     147msgstr ""
     148
     149#: classes/Controllers/User.php:627
     150msgid "2FA enabled: EXCLUDED"
     151msgstr ""
     152
     153#: classes/Controllers/User.php:631
     154msgid "TOTP enabled: YES"
     155msgstr ""
     156
     157#: classes/Helpers/Information/ModuleInformation.php:49
     158msgid "Disabled: "
     159msgstr ""
     160
     161#: classes/Helpers/NotifyAdmin.php:39
     162msgid "Maximum number of unsuccessful login attempts reached"
     163msgstr ""
     164
     165#: classes/Helpers/OutOfBandEmail.php:93
     166msgid "One time login link"
     167msgstr ""
     168
     169#: classes/Helpers/OutOfBandEmail.php:128
     170msgid "Out of bond email link"
     171msgstr ""
     172
     173#: classes/Secured.php:70
     174msgid "Settings"
     175msgstr ""
     176
     177#. translators: %1$s: PHP version
     178#: classes/Secured.php:93
     179msgid "You need to update your PHP version to %1s."
     180msgstr ""
     181
     182#: classes/Secured.php:98
     183#: classes/Secured.php:119
     184msgid "Actual version is:"
     185msgstr ""
     186
     187#. translators: %1$s: WP version
     188#: classes/Secured.php:114
     189msgid "You need to update your WP version to %1s."
     190msgstr ""
     191
     192#: classes/Secured.php:239
     193msgid "You must be logged in to see this content"
     194msgstr ""
     195
     196#: classes/Validators/Validator.php:64
     197#: classes/Validators/Validator.php:94
     198msgid "No rules are set - nothing to test against"
     199msgstr ""
     200
     201#: classes/Validators/Validator.php:72
     202msgid "Variable is not set"
     203msgstr ""
     204
     205#: classes/Validators/Validator.php:126
     206msgid "Variable is not valid e-mail"
     207msgstr ""
     208
     209#: classes/Validators/Validator.php:191
     210msgid "Variable is not integer"
     211msgstr ""
     212
     213#: classes/Validators/Validator.php:195
     214#: classes/Validators/Validator.php:211
     215msgid "Variable is not positive integer!"
     216msgstr ""
     217
     218#: classes/Validators/Validator.php:214
     219msgid "Variable is not in given range"
     220msgstr ""
     221
     222#: classes/Views/AdminSettingsView.php:104
     223msgid "Information"
     224msgstr ""
     225
     226#: classes/Views/AdminSettingsView.php:110
     227msgid "Provides Security for WP sites"
     228msgstr ""
     229
     230#: classes/Views/AdminSettingsView.php:115
     231msgid "Version"
     232msgstr ""
     233
     234#: classes/Views/AdminSettingsView.php:119
     235msgid "Delete data on plugin uninstall"
     236msgstr ""
     237
     238#: classes/Views/AdminSettingsView.php:122
     239msgid "That setting is global"
     240msgstr ""
     241
     242#: classes/Views/AdminSettingsView.php:126
     243msgid "Modules Information"
     244msgstr ""
     245
     246#: classes/Views/AdminSettingsView.php:137
     247#: classes/Views/AdminSettingsView.php:155
     248msgid "Save Changes"
     249msgstr ""
     250
     251#: classes/Views/AdminSettingsView.php:163
     252msgid "Restore Default Plugin Settings"
     253msgstr ""
     254
     255#: classes/Views/AdminSettingsView.php:177
     256msgid "Are you sure you want to restore the defaults? All settings will be overridden"
     257msgstr ""
     258
     259#: classes/Views/AdminSettingsView.php:182
     260msgid "Are you sure you want to restore the defaults? All module settings will be overridden"
     261msgstr ""
     262
     263#: classes/Views/LoginForms.php:122
     264msgid "Scan above with your favorite Authenticator Application and enter the code below or add the following code:"
     265msgstr ""
     266
     267#: classes/Views/LoginForms.php:125
     268msgid "Open the Authenticator Application on your phone and enter the code for "
     269msgstr ""
     270
     271#: classes/Views/LoginForms.php:129
     272msgid "Authentication Code:"
     273msgstr ""
     274
     275#: classes/Views/LoginForms.php:135
     276#: classes/Views/LoginForms.php:209
     277msgid "Log In"
     278msgstr ""
     279
     280#: classes/Views/LoginForms.php:203
     281msgid "Click the button to finish the login."
     282msgstr ""
     283
     284#: classes/Views/LoginForms.php:236
     285msgid "You have logged in successfully."
     286msgstr ""
     287
     288#: classes/Views/LoginForms.php:286
     289msgid "Send me out of bond email instead"
     290msgstr ""
     291
     292#: classes/Views/SettingsTabs.php:52
     293msgid "Login redirection Settings"
     294msgstr ""
     295
     296#: classes/Views/SettingsTabs.php:55
     297msgid "Disable Login Redirection"
     298msgstr ""
     299
     300#: classes/Views/SettingsTabs.php:56
     301#: classes/Views/SettingsTabs.php:111
     302#: classes/Views/SettingsTabs.php:173
     303#: classes/Views/SettingsTabs.php:226
     304#: classes/Views/SettingsTabs.php:281
     305msgid "Description:"
     306msgstr ""
     307
     308#: classes/Views/SettingsTabs.php:58
     309#: classes/Views/SettingsTabs.php:114
     310#: classes/Views/SettingsTabs.php:176
     311#: classes/Views/SettingsTabs.php:229
     312#: classes/Views/SettingsTabs.php:284
     313msgid "These settings are blog related (multisite)"
     314msgstr ""
     315
     316#: classes/Views/SettingsTabs.php:63
     317msgid "New Login redirection slug"
     318msgstr ""
     319
     320#: classes/Views/SettingsTabs.php:66
     321msgid "New login redirection slug"
     322msgstr ""
     323
     324#: classes/Views/SettingsTabs.php:71
     325#: classes/Views/SettingsTabs.php:74
     326msgid "Redirect original login to"
     327msgstr ""
     328
     329#: classes/Views/SettingsTabs.php:79
     330#: classes/Views/SettingsTabs.php:141
     331#: classes/Views/SettingsTabs.php:195
     332#: classes/Views/SettingsTabs.php:250
     333#: classes/Views/SettingsTabs.php:289
     334msgid "Default Settings"
     335msgstr ""
     336
     337#: classes/Views/SettingsTabs.php:83
     338#: classes/Views/SettingsTabs.php:145
     339#: classes/Views/SettingsTabs.php:199
     340#: classes/Views/SettingsTabs.php:254
     341#: classes/Views/SettingsTabs.php:293
     342msgid "Restore Module Default Settings"
     343msgstr ""
     344
     345#: classes/Views/SettingsTabs.php:89
     346#: classes/Views/SettingsTabs.php:151
     347#: classes/Views/SettingsTabs.php:205
     348msgid "This will restore module settings to defaults."
     349msgstr ""
     350
     351#: classes/Views/SettingsTabs.php:107
     352msgid "Login Attempts Settings"
     353msgstr ""
     354
     355#: classes/Views/SettingsTabs.php:110
     356msgid "Disable Login Attempts"
     357msgstr ""
     358
     359#: classes/Views/SettingsTabs.php:136
     360msgid "How many minutes to lock the user"
     361msgstr ""
     362
     363#: classes/Views/SettingsTabs.php:169
     364msgid "Remember Device Settings"
     365msgstr ""
     366
     367#: classes/Views/SettingsTabs.php:172
     368msgid "Disable Remember Devices"
     369msgstr ""
     370
     371#: classes/Views/SettingsTabs.php:181
     372msgid "Remember Device Time"
     373msgstr ""
     374
     375#: classes/Views/SettingsTabs.php:190
     376msgid "How many days remember device"
     377msgstr ""
     378
     379#: classes/Views/SettingsTabs.php:222
     380msgid "2FA Settings"
     381msgstr ""
     382
     383#: classes/Views/SettingsTabs.php:225
     384msgid "Disable 2FA"
     385msgstr ""
     386
     387#: classes/Views/SettingsTabs.php:234
     388msgid "TOTP "
     389msgstr ""
     390
     391#: classes/Views/SettingsTabs.php:242
     392msgid "Out of bond e-mail "
     393msgstr ""
     394
     395#: classes/Views/SettingsTabs.php:260
     396#: classes/Views/SettingsTabs.php:299
     397msgid "This will restore plugin settings to defaults."
     398msgstr ""
     399
     400#: classes/Views/SettingsTabs.php:277
     401msgid "XML-RPC Settings"
     402msgstr ""
     403
     404#: classes/Views/SettingsTabs.php:280
     405msgid "Enable XML-RPC"
     406msgstr ""
     407
     408#: classes/Views/UserProfile.php:54
     409msgid "Secured WP - Options"
     410msgstr ""
     411
     412#: classes/Views/UserProfile.php:55
     413msgid "Current devices with \"Remember Me\" option enabled"
     414msgstr ""
     415
     416#: classes/Views/UserProfile.php:60
     417#: classes/Views/UserProfile.php:122
     418msgid "Device"
     419msgstr ""
     420
     421#: classes/Views/UserProfile.php:63
     422#: classes/Views/UserProfile.php:125
     423msgid "Expires"
     424msgstr ""
     425
     426#: classes/Views/UserProfile.php:66
     427#: classes/Views/UserProfile.php:99
     428#: classes/Views/UserProfile.php:128
     429msgid "Remove"
     430msgstr ""
     431
     432#: classes/Views/UserProfile.php:76
     433msgid "No logged in devices found"
     434msgstr ""
     435
     436#: classes/Views/UserProfile.php:90
     437msgid "Expired"
     438msgstr ""
     439
     440#: classes/Views/UserProfile.php:139
     441msgid "Remove all logged in devices"
     442msgstr ""
     443
     444#: classes/Views/UserProfile.php:174
     445msgid "QR code for the TOTP 2FA login"
     446msgstr ""
     447
     448#: classes/Views/UserProfile.php:187
     449msgid "Or use the following key, by entering it directly in you preferable authentication application:"
     450msgstr ""
     451
     452#: classes/Views/UserProfile.php:200
     453msgid "Regenerate QR code"
     454msgstr ""
     455
     456#: classes/Views/UsersList.php:177
     457msgid "Locked status"
     458msgstr ""
     459
     460#: classes/Views/UsersList.php:210
     461msgid "Locked"
     462msgstr ""
     463
     464#: classes/Views/UsersList.php:210
     465msgid "Not Locked"
     466msgstr ""
     467
     468#: classes/Views/UsersList.php:228
     469msgid "Secured WP Status"
     470msgstr ""
     471
     472#: classes/Views/UsersList.php:265
     473#: classes/Views/UsersList.php:327
     474msgid "Logged in"
     475msgstr ""
     476
     477#: classes/Views/UsersList.php:284
     478msgid "Logged"
     479msgstr ""
     480
     481#: classes/Views/UsersList.php:284
     482msgid "Not Logged"
     483msgstr ""
     484
     485#: classes/Views/UsersList.php:347
     486msgid "Lock Users"
     487msgstr ""
     488
     489#: classes/Views/UsersList.php:348
     490msgid "Unlock Users"
     491msgstr ""
     492
     493#: classes/Views/UsersList.php:350
     494msgid "Exclude from WP 2FA"
     495msgstr ""
     496
     497#: classes/Views/UsersList.php:351
     498msgid "Include in WP 2FA"
     499msgstr ""
     500
     501#. translators: %s: Number of users
     502#: classes/Views/UsersList.php:431
     503msgid "Locked %s user."
     504msgid_plural "Locked %s users."
     505msgstr[0] ""
     506msgstr[1] ""
     507
     508#. translators: %s: Number of users
     509#: classes/Views/UsersList.php:447
     510msgid "Unlocked %s user."
     511msgid_plural "Unlocked %s users."
     512msgstr[0] ""
     513msgstr[1] ""
     514
     515#: classes/Views/UsersList.php:475
     516#: classes/Views/UsersList.php:477
     517msgid "Filter Role"
     518msgstr ""
     519
     520#. translators: %s: Customer username
     521#: templates/template-oob.php:14
     522msgid "Hi %s,"
     523msgstr ""
  • secured-wp/tags/1.7/readme.txt

    r2579464 r2636555  
    55Tested up to: 5.8
    66Requires PHP: 7.2
    7 Stable tag: 1.5
     7Stable tag: 1.6
    88License: GPLv2 or later
    99License URI: http://www.gnu.org/licenses/gpl-2.0.html
     
    1212
    1313== Description ==
    14 Adds layer of security for your WordPress site. Adds custom login page slug, enables 2FA, removes security issues. Adds remember device, counts login attempts and lock usernames if the password is wrong. Out of bond e-mail is also supported - instead of entering codes, your user can use simple login link from within their e-mail client.
     14Adds layer of security for your WordPress site. Adds custom login page slug, enables 2FA, removes security issues. Adds remember device, counts login attempts and lock usernames if the password is wrong. Out of band e-mail is also supported - instead of entering codes, your user can use simple login link from within their e-mail client.
    1515
    1616<strong>Woocommerce</strong>
     
    22221. <strong>Login redirection</strong> - redirects the default wp-login.php to a slug of your choice
    23232. <strong>Login attempts</strong> - counts the unsuccessful attempts, and locks user if there are too many
    24 3. <strong>2FA settings</strong> - gives the ability to use two factor authentication and Out Of Bond email link
     243. <strong>2FA settings</strong> - gives the ability to use two factor authentication and Out Of Band email link
    25254. <strong>Remember devices</strong> - current device could be remembered for given amount of days and user wont be asked to login again before that
    26265. <strong>Removes XML-RPC</strong> from your WordPress site
     
    68681. Main screen of the plugin, settings tabs and information about the settings
    69692. 2FA login screen, user does not have enabled 2FA yet
    70 3. E-mail with the Out of Bond link
     703. E-mail with the Out of Band link
    71714. Woocommerce My Profile page
    72725. Extends default Users menu bulk actions
  • secured-wp/tags/1.7/secured-wp.php

    r2579464 r2636555  
    1616 * Plugin URI:        https://wp-secured.com
    1717 * Description:       Provides Security for WP sites. 2FA, login attempts, hardens WP login process
    18  * Version:           1.5
     18 * Version:           1.7
    1919 * Author:            wp-secured
    2020 * Author URI:        https://wp-secured.com
     
    2222 * License:           GPL-2.0+
    2323 * License URI:       http://www.gnu.org/licenses/gpl-2.0.txt
    24  * Text Domain:       wp-secured
     24 * Text Domain:       secured-wp
    2525 * Domain Path:       /languages
    2626 * License:           GPL2 or later
  • secured-wp/tags/1.7/vendor/composer/autoload_psr4.php

    r2576070 r2636555  
    1313    'ParagonIE\\ConstantTime\\' => array($vendorDir . '/paragonie/constant_time_encoding/src'),
    1414    'OTPHP\\' => array($vendorDir . '/spomky-labs/otphp/src'),
     15    'Endroid\\QrCode\\' => array($vendorDir . '/endroid/qr-code/src'),
     16    'DASPRiD\\Enum\\' => array($vendorDir . '/dasprid/enum/src'),
     17    'BaconQrCode\\' => array($vendorDir . '/bacon/bacon-qr-code/src'),
    1518    'Assert\\' => array($vendorDir . '/beberlei/assert/lib/Assert'),
    1619);
  • secured-wp/tags/1.7/vendor/composer/autoload_static.php

    r2576070 r2636555  
    122122            'OTPHP\\' => 6,
    123123        ),
     124        'E' =>
     125        array (
     126            'Endroid\\QrCode\\' => 15,
     127        ),
     128        'D' =>
     129        array (
     130            'DASPRiD\\Enum\\' => 13,
     131        ),
     132        'B' =>
     133        array (
     134            'BaconQrCode\\' => 12,
     135        ),
    124136        'A' =>
    125137        array (
     
    154166        array (
    155167            0 => __DIR__ . '/..' . '/spomky-labs/otphp/src',
     168        ),
     169        'Endroid\\QrCode\\' =>
     170        array (
     171            0 => __DIR__ . '/..' . '/endroid/qr-code/src',
     172        ),
     173        'DASPRiD\\Enum\\' =>
     174        array (
     175            0 => __DIR__ . '/..' . '/dasprid/enum/src',
     176        ),
     177        'BaconQrCode\\' =>
     178        array (
     179            0 => __DIR__ . '/..' . '/bacon/bacon-qr-code/src',
    156180        ),
    157181        'Assert\\' =>
  • secured-wp/tags/1.7/vendor/composer/installed.json

    r2576070 r2636555  
    11[
     2    {
     3        "name": "bacon/bacon-qr-code",
     4        "version": "2.0.4",
     5        "version_normalized": "2.0.4.0",
     6        "source": {
     7            "type": "git",
     8            "url": "https://github.com/Bacon/BaconQrCode.git",
     9            "reference": "f73543ac4e1def05f1a70bcd1525c8a157a1ad09"
     10        },
     11        "dist": {
     12            "type": "zip",
     13            "url": "https://api.github.com/repos/Bacon/BaconQrCode/zipball/f73543ac4e1def05f1a70bcd1525c8a157a1ad09",
     14            "reference": "f73543ac4e1def05f1a70bcd1525c8a157a1ad09",
     15            "shasum": ""
     16        },
     17        "require": {
     18            "dasprid/enum": "^1.0.3",
     19            "ext-iconv": "*",
     20            "php": "^7.1 || ^8.0"
     21        },
     22        "require-dev": {
     23            "phly/keep-a-changelog": "^1.4",
     24            "phpunit/phpunit": "^7 | ^8 | ^9",
     25            "squizlabs/php_codesniffer": "^3.4"
     26        },
     27        "suggest": {
     28            "ext-imagick": "to generate QR code images"
     29        },
     30        "time": "2021-06-18T13:26:35+00:00",
     31        "type": "library",
     32        "installation-source": "dist",
     33        "autoload": {
     34            "psr-4": {
     35                "BaconQrCode\\": "src/"
     36            }
     37        },
     38        "notification-url": "https://packagist.org/downloads/",
     39        "license": [
     40            "BSD-2-Clause"
     41        ],
     42        "authors": [
     43            {
     44                "name": "Ben Scholzen 'DASPRiD'",
     45                "email": "mail@dasprids.de",
     46                "homepage": "https://dasprids.de/",
     47                "role": "Developer"
     48            }
     49        ],
     50        "description": "BaconQrCode is a QR code generator for PHP.",
     51        "homepage": "https://github.com/Bacon/BaconQrCode"
     52    },
    253    {
    354        "name": "beberlei/assert",
     
    63114            "assertion",
    64115            "validation"
     116        ]
     117    },
     118    {
     119        "name": "dasprid/enum",
     120        "version": "1.0.3",
     121        "version_normalized": "1.0.3.0",
     122        "source": {
     123            "type": "git",
     124            "url": "https://github.com/DASPRiD/Enum.git",
     125            "reference": "5abf82f213618696dda8e3bf6f64dd042d8542b2"
     126        },
     127        "dist": {
     128            "type": "zip",
     129            "url": "https://api.github.com/repos/DASPRiD/Enum/zipball/5abf82f213618696dda8e3bf6f64dd042d8542b2",
     130            "reference": "5abf82f213618696dda8e3bf6f64dd042d8542b2",
     131            "shasum": ""
     132        },
     133        "require-dev": {
     134            "phpunit/phpunit": "^7 | ^8 | ^9",
     135            "squizlabs/php_codesniffer": "^3.4"
     136        },
     137        "time": "2020-10-02T16:03:48+00:00",
     138        "type": "library",
     139        "installation-source": "dist",
     140        "autoload": {
     141            "psr-4": {
     142                "DASPRiD\\Enum\\": "src/"
     143            }
     144        },
     145        "notification-url": "https://packagist.org/downloads/",
     146        "license": [
     147            "BSD-2-Clause"
     148        ],
     149        "authors": [
     150            {
     151                "name": "Ben Scholzen 'DASPRiD'",
     152                "email": "mail@dasprids.de",
     153                "homepage": "https://dasprids.de/",
     154                "role": "Developer"
     155            }
     156        ],
     157        "description": "PHP 7.1 enum implementation",
     158        "keywords": [
     159            "enum",
     160            "map"
     161        ]
     162    },
     163    {
     164        "name": "endroid/qr-code",
     165        "version": "4.3.4",
     166        "version_normalized": "4.3.4.0",
     167        "source": {
     168            "type": "git",
     169            "url": "https://github.com/endroid/qr-code.git",
     170            "reference": "4832304da7c3c0e958c968914185a01ac24cfce4"
     171        },
     172        "dist": {
     173            "type": "zip",
     174            "url": "https://api.github.com/repos/endroid/qr-code/zipball/4832304da7c3c0e958c968914185a01ac24cfce4",
     175            "reference": "4832304da7c3c0e958c968914185a01ac24cfce4",
     176            "shasum": ""
     177        },
     178        "require": {
     179            "bacon/bacon-qr-code": "^2.0",
     180            "php": "^7.3||^8.0"
     181        },
     182        "require-dev": {
     183            "endroid/quality": "dev-master",
     184            "ext-gd": "*",
     185            "khanamiryan/qrcode-detector-decoder": "^1.0.4",
     186            "setasign/fpdf": "^1.8.2"
     187        },
     188        "suggest": {
     189            "ext-gd": "Enables you to write PNG images",
     190            "khanamiryan/qrcode-detector-decoder": "Enables you to use the image validator",
     191            "roave/security-advisories": "Makes sure package versions with known security issues are not installed",
     192            "setasign/fpdf": "Enables you to use the PDF writer"
     193        },
     194        "time": "2021-09-16T18:33:57+00:00",
     195        "type": "library",
     196        "extra": {
     197            "branch-alias": {
     198                "dev-master": "4.x-dev"
     199            }
     200        },
     201        "installation-source": "dist",
     202        "autoload": {
     203            "psr-4": {
     204                "Endroid\\QrCode\\": "src/"
     205            }
     206        },
     207        "notification-url": "https://packagist.org/downloads/",
     208        "license": [
     209            "MIT"
     210        ],
     211        "authors": [
     212            {
     213                "name": "Jeroen van den Enden",
     214                "email": "info@endroid.nl"
     215            }
     216        ],
     217        "description": "Endroid QR Code",
     218        "homepage": "https://github.com/endroid/qr-code",
     219        "keywords": [
     220            "code",
     221            "endroid",
     222            "php",
     223            "qr",
     224            "qrcode"
     225        ],
     226        "funding": [
     227            {
     228                "url": "https://github.com/endroid",
     229                "type": "github"
     230            }
    65231        ]
    66232    },
     
    191357    {
    192358        "name": "scssphp/scssphp",
    193         "version": "v1.6.0",
    194         "version_normalized": "1.6.0.0",
     359        "version": "v1.8.1",
     360        "version_normalized": "1.8.1.0",
    195361        "source": {
    196362            "type": "git",
    197363            "url": "https://github.com/scssphp/scssphp.git",
    198             "reference": "b83594e2323c5d6e80785df3f91b9d1d32aad530"
    199         },
    200         "dist": {
    201             "type": "zip",
    202             "url": "https://api.github.com/repos/scssphp/scssphp/zipball/b83594e2323c5d6e80785df3f91b9d1d32aad530",
    203             "reference": "b83594e2323c5d6e80785df3f91b9d1d32aad530",
     364            "reference": "5e37759a63caf54392a4b709358a39ac7425a69f"
     365        },
     366        "dist": {
     367            "type": "zip",
     368            "url": "https://api.github.com/repos/scssphp/scssphp/zipball/5e37759a63caf54392a4b709358a39ac7425a69f",
     369            "reference": "5e37759a63caf54392a4b709358a39ac7425a69f",
    204370            "shasum": ""
    205371        },
     
    215381            "squizlabs/php_codesniffer": "~3.5",
    216382            "symfony/phpunit-bridge": "^5.1",
     383            "thoughtbot/bourbon": "^7.0",
    217384            "twbs/bootstrap": "~5.0",
    218385            "twbs/bootstrap4": "4.6.0",
     
    223390            "ext-mbstring": "For best performance, mbstring should be installed as it is faster than ext-iconv"
    224391        },
    225         "time": "2021-07-02T16:28:10+00:00",
     392        "time": "2021-09-18T21:20:53+00:00",
    226393        "bin": [
    227394            "bin/pscss"
  • secured-wp/tags/1.7/vendor/scssphp/scssphp/bin/pscss

    r2576070 r2636555  
    2727
    2828$style = null;
    29 $loadPaths = null;
     29$loadPaths = [];
    3030$dumpTree = false;
    3131$inputFile = null;
     
    149149
    150150    if (isset($value)) {
    151         $loadPaths = $value;
     151        $loadPaths[] = $value;
    152152        continue;
    153153    }
     
    189189
    190190if ($loadPaths) {
    191     $scss->setImportPaths(explode(PATH_SEPARATOR, $loadPaths));
     191    $scss->setImportPaths($loadPaths);
    192192}
    193193
  • secured-wp/tags/1.7/vendor/scssphp/scssphp/composer.json

    r2576070 r2636555  
    4141        "squizlabs/php_codesniffer": "~3.5",
    4242        "symfony/phpunit-bridge": "^5.1",
     43        "thoughtbot/bourbon": "^7.0",
    4344        "twbs/bootstrap": "~5.0",
    4445        "twbs/bootstrap4": "4.6.0",
     
    5051            "package": {
    5152                "name": "sass/sass-spec",
    52                 "version": "2021.06.30",
     53                "version": "2021.09.15",
    5354                "source": {
    5455                    "type": "git",
    5556                    "url": "https://github.com/sass/sass-spec.git",
    56                     "reference": "e348959657f1e274cef658283436a311a925a673"
     57                    "reference": "eb2d7a0865c1faf0b55a39ff962b24aca9b4c955"
    5758                },
    5859                "dist": {
    5960                    "type": "zip",
    60                     "url": "https://api.github.com/repos/sass/sass-spec/zipball/e348959657f1e274cef658283436a311a925a673",
    61                     "reference": "e348959657f1e274cef658283436a311a925a673",
     61                    "url": "https://api.github.com/repos/sass/sass-spec/zipball/eb2d7a0865c1faf0b55a39ff962b24aca9b4c955",
     62                    "reference": "eb2d7a0865c1faf0b55a39ff962b24aca9b4c955",
     63                    "shasum": ""
     64                }
     65            }
     66        },
     67        {
     68            "type": "package",
     69            "package": {
     70                "name": "thoughtbot/bourbon",
     71                "version": "v7.0.0",
     72                "source": {
     73                    "type": "git",
     74                    "url": "https://github.com/thoughtbot/bourbon.git",
     75                    "reference": "fbe338ee6807e7f7aa996d82c8a16f248bb149b3"
     76                },
     77                "dist": {
     78                    "type": "zip",
     79                    "url": "https://api.github.com/repos/thoughtbot/bourbon/zipball/fbe338ee6807e7f7aa996d82c8a16f248bb149b3",
     80                    "reference": "fbe338ee6807e7f7aa996d82c8a16f248bb149b3",
    6281                    "shasum": ""
    6382                }
  • secured-wp/tags/1.7/vendor/scssphp/scssphp/src/Compiler.php

    r2576070 r2636555  
    195195
    196196    /**
     197     * @var bool
     198     */
     199    private $charset = true;
     200
     201    /**
    197202     * @var string|\ScssPhp\ScssPhp\Formatter
    198203     */
     
    222227    /**
    223228     * @var bool|null
     229     *
     230     * @deprecated
    224231     */
    225232    protected $charsetSeen;
     
    464471        $this->scope          = null;
    465472        $this->storeEnv       = null;
    466         $this->charsetSeen    = null;
    467473        $this->shouldEvaluate = null;
    468474        $this->ignoreCallStackMessage = false;
     
    517523            $prefix = '';
    518524
    519             if (!$this->charsetSeen) {
    520                 if (strlen($out) !== Util::mbStrlen($out)) {
    521                     $prefix = '@charset "UTF-8";' . "\n";
    522                     $out = $prefix . $out;
    523                 }
     525            if ($this->charset && strlen($out) !== Util::mbStrlen($out)) {
     526                $prefix = '@charset "UTF-8";' . "\n";
     527                $out = $prefix . $out;
    524528            }
    525529
     
    28782882
    28792883            case Type::T_CHARSET:
    2880                 if (! $this->charsetSeen) {
    2881                     $this->charsetSeen = true;
    2882                     $this->appendRootDirective('@charset ' . $this->compileValue($child[1]) . ';', $out);
    2883                 }
    28842884                break;
    28852885
     
    38283828        // try to find a native lib function
    38293829        $normalizedName = $this->normalizeName($name);
    3830         $libName = null;
    38313830
    38323831        if (isset($this->userFunctions[$normalizedName])) {
     
    38373836        }
    38383837
     3838        $lowercasedName = strtolower($normalizedName);
     3839
     3840        // Special functions overriding a CSS function are case-insensitive. We normalize them as lowercase
     3841        // to avoid the deprecation warning about the wrong case being used.
     3842        if ($lowercasedName === 'min' || $lowercasedName === 'max') {
     3843            $normalizedName = $lowercasedName;
     3844        }
     3845
    38393846        if (($f = $this->getBuiltinFunction($normalizedName)) && \is_callable($f)) {
    38403847            $libName   = $f[1];
    38413848            $prototype = isset(static::$$libName) ? static::$$libName : null;
     3849
     3850            // All core functions have a prototype defined. Not finding the
     3851            // prototype can mean 2 things:
     3852            // - the function comes from a child class (deprecated just after)
     3853            // - the function was found with a different case, which relates to calling the
     3854            //   wrong Sass function due to our camelCase usage (`fade-in()` vs `fadein()`),
     3855            //   because PHP method names are case-insensitive while property names are
     3856            //   case-sensitive.
     3857            if ($prototype === null || strtolower($normalizedName) !== $normalizedName) {
     3858                $r = new \ReflectionMethod($this, $libName);
     3859                $actualLibName = $r->name;
     3860
     3861                if ($actualLibName !== $libName || strtolower($normalizedName) !== $normalizedName) {
     3862                    $kebabCaseName = preg_replace('~(?<=\\w)([A-Z])~', '-$1', substr($actualLibName, 3));
     3863                    assert($kebabCaseName !== null);
     3864                    $originalName = strtolower($kebabCaseName);
     3865                    $warning = "Calling built-in functions with a non-standard name is deprecated since Scssphp 1.8.0 and will not work anymore in 2.0 (they will be treated as CSS function calls instead).\nUse \"$originalName\" instead of \"$name\".";
     3866                    @trigger_error($warning, E_USER_DEPRECATED);
     3867                    $fname = $this->getPrettyPath($this->sourceNames[$this->sourceIndex]);
     3868                    $line  = $this->sourceLine;
     3869                    Warn::deprecation("$warning\n         on line $line of $fname");
     3870
     3871                    // Use the actual function definition
     3872                    $prototype = isset(static::$$actualLibName) ? static::$$actualLibName : null;
     3873                    $f[1] = $libName = $actualLibName;
     3874                }
     3875            }
    38423876
    38433877            if (\get_class($this) !== __CLASS__ && !isset($this->warnedChildFunctions[$libName])) {
     
    55005534
    55015535    /**
     5536     * Configures the handling of non-ASCII outputs.
     5537     *
     5538     * If $charset is `true`, this will include a `@charset` declaration or a
     5539     * UTF-8 [byte-order mark][] if the stylesheet contains any non-ASCII
     5540     * characters. Otherwise, it will never include a `@charset` declaration or a
     5541     * byte-order mark.
     5542     *
     5543     * [byte-order mark]: https://en.wikipedia.org/wiki/Byte_order_mark#UTF-8
     5544     *
     5545     * @param bool $charset
     5546     *
     5547     * @return void
     5548     */
     5549    public function setCharset($charset)
     5550    {
     5551        $this->charset = $charset;
     5552    }
     5553
     5554    /**
    55025555     * Enable/disable source maps
    55035556     *
     
    58735926
    58745927        if (0 === strpos($normalizedPath, $normalizedRootDirectory)) {
    5875             return substr($normalizedPath, \strlen($normalizedRootDirectory));
     5928            return substr($path, \strlen($normalizedRootDirectory));
    58765929        }
    58775930
     
    72107263     *
    72117264     * @return integer|float
     7265     *
     7266     * @deprecated
    72127267     */
    72137268    protected function coercePercent($value)
    72147269    {
     7270        @trigger_error(sprintf('"%s" is deprecated since 1.7.0.', __METHOD__), E_USER_DEPRECATED);
     7271
    72157272        if ($value instanceof Number) {
    72167273            if ($value->hasUnit('%')) {
     
    74397496        }
    74407497
    7441         return [Type::T_HSL, fmod($h, 360), $s * 100, $l / 5.1];
     7498        return [Type::T_HSL, fmod($h + 360, 360), $s * 100, $l / 5.1];
    74427499    }
    74437500
     
    77207777                    }
    77217778                } else {
    7722                     $color = [Type::T_STRING, '', [$funcName . '(', $args[0], ')']];
     7779                    $color = [Type::T_STRING, '', [$funcName . '(', $args[0], ', ', $args[1], ')']];
    77237780                }
    77247781                break;
     
    80218078    // mix two colors
    80228079    protected static $libMix = [
    8023         ['color1', 'color2', 'weight:0.5'],
    8024         ['color-1', 'color-2', 'weight:0.5']
     8080        ['color1', 'color2', 'weight:50%'],
     8081        ['color-1', 'color-2', 'weight:50%']
    80258082        ];
    80268083    protected function libMix($args)
     
    80308087        $first = $this->assertColor($first, 'color1');
    80318088        $second = $this->assertColor($second, 'color2');
    8032         $weight = $this->coercePercent($this->assertNumber($weight, 'weight'));
     8089        $weightScale = $this->assertNumber($weight, 'weight')->valueInRange(0, 100, 'weight') / 100;
    80338090
    80348091        $firstAlpha = isset($first[4]) ? $first[4] : 1;
    80358092        $secondAlpha = isset($second[4]) ? $second[4] : 1;
    80368093
    8037         $w = $weight * 2 - 1;
    8038         $a = $firstAlpha - $secondAlpha;
    8039 
    8040         $w1 = (($w * $a === -1 ? $w : ($w + $a) / (1 + $w * $a)) + 1) / 2.0;
    8041         $w2 = 1.0 - $w1;
     8094        $normalizedWeight = $weightScale * 2 - 1;
     8095        $alphaDistance = $firstAlpha - $secondAlpha;
     8096
     8097        $combinedWeight = $normalizedWeight * $alphaDistance == -1 ? $normalizedWeight : ($normalizedWeight + $alphaDistance) / (1 + $normalizedWeight * $alphaDistance);
     8098        $weight1 = ($combinedWeight + 1) / 2.0;
     8099        $weight2 = 1.0 - $weight1;
    80428100
    80438101        $new = [Type::T_COLOR,
    8044             $w1 * $first[1] + $w2 * $second[1],
    8045             $w1 * $first[2] + $w2 * $second[2],
    8046             $w1 * $first[3] + $w2 * $second[3],
     8102            $weight1 * $first[1] + $weight2 * $second[1],
     8103            $weight1 * $first[2] + $weight2 * $second[2],
     8104            $weight1 * $first[3] + $weight2 * $second[3],
    80478105        ];
    80488106
    80498107        if ($firstAlpha != 1.0 || $secondAlpha != 1.0) {
    8050             $new[] = $firstAlpha * $weight + $secondAlpha * (1 - $weight);
     8108            $new[] = $firstAlpha * $weightScale + $secondAlpha * (1 - $weightScale);
    80518109        }
    80528110
     
    81258183        }
    81268184
    8127         $hueValue = $hue->getDimension() % 360;
     8185        $hueValue = fmod($hue->getDimension(), 360);
    81288186
    81298187        while ($hueValue < 0) {
     
    83078365        $hsl = $this->toHSL($color[1], $color[2], $color[3]);
    83088366        $hsl[$idx] += $amount;
     8367
     8368        if ($idx !== 1) {
     8369            // Clamp the saturation and lightness
     8370            $hsl[$idx] = min(max(0, $hsl[$idx]), 100);
     8371        }
     8372
    83098373        $out = $this->toRGB($hsl[1], $hsl[2], $hsl[3]);
    83108374
     
    83548418        }
    83558419
    8356         $color = $this->assertColor($value, 'color');
    8357         $amount = 100 * $this->coercePercent($this->assertNumber($args[1], 'amount'));
    8358 
    8359         return $this->adjustHsl($color, 2, $amount);
     8420        $color = $this->assertColor($args[0], 'color');
     8421        $amount = $this->assertNumber($args[1], 'amount');
     8422
     8423        return $this->adjustHsl($color, 2, $amount->valueInRange(0, 100, 'amount'));
    83608424    }
    83618425
     
    83648428    {
    83658429        $color = $this->assertColor($args[0], 'color');
    8366         $amount = 100 * $this->coercePercent($this->assertNumber($args[1], 'amount'));
    8367 
    8368         return $this->adjustHsl($color, 2, -$amount);
     8430        $amount = $this->assertNumber($args[1], 'amount');
     8431
     8432        return $this->adjustHsl($color, 2, -$amount->valueInRange(0, 100, 'amount'));
    83698433    }
    83708434
     
    83878451    }
    83888452
    8389     protected static $libInvert = ['color', 'weight:1'];
     8453    protected static $libInvert = ['color', 'weight:100%'];
    83908454    protected function libInvert($args)
    83918455    {
    83928456        $value = $args[0];
    83938457
     8458        $weight = $this->assertNumber($args[1], 'weight');
     8459
    83948460        if ($value instanceof Number) {
     8461            if ($weight->getDimension() != 100 || !$weight->hasUnit('%')) {
     8462                throw new SassScriptException('Only one argument may be passed to the plain-CSS invert() function.');
     8463            }
     8464
    83958465            return null;
    83968466        }
    8397 
    8398         $weight = $this->coercePercent($this->assertNumber($args[1], 'weight'));
    83998467
    84008468        $color = $this->assertColor($value, 'color');
     
    84048472        $inverted[3] = 255 - $inverted[3];
    84058473
    8406         if ($weight < 1) {
    8407             return $this->libMix([$inverted, $color, new Number($weight, '')]);
    8408         }
    8409 
    8410         return $inverted;
     8474        return $this->libMix([$inverted, $color, $weight]);
    84118475    }
    84128476
     
    84168480    {
    84178481        $color = $this->assertColor($args[0], 'color');
    8418         $amount = $this->coercePercent($this->assertNumber($args[1], 'amount'));
    8419 
    8420         $color[4] = (isset($color[4]) ? $color[4] : 1) + $amount;
     8482        $amount = $this->assertNumber($args[1], 'amount');
     8483
     8484        $color[4] = (isset($color[4]) ? $color[4] : 1) + $amount->valueInRange(0, 1, 'amount');
    84218485        $color[4] = min(1, max(0, $color[4]));
    84228486
     
    84358499    {
    84368500        $color = $this->assertColor($args[0], 'color');
    8437         $amount = $this->coercePercent($this->assertNumber($args[1], 'amount'));
    8438 
    8439         $color[4] = (isset($color[4]) ? $color[4] : 1) - $amount;
     8501        $amount = $this->assertNumber($args[1], 'amount');
     8502
     8503        $color[4] = (isset($color[4]) ? $color[4] : 1) - $amount->valueInRange(0, 1, 'amount');
    84408504        $color[4] = min(1, max(0, $color[4]));
    84418505
  • secured-wp/tags/1.7/vendor/scssphp/scssphp/src/Node/Number.php

    r2576070 r2636555  
    150150     * {@inheritdoc}
    151151     */
     152    #[\ReturnTypeWillChange]
    152153    public function offsetExists($offset)
    153154    {
     
    175176     * {@inheritdoc}
    176177     */
     178    #[\ReturnTypeWillChange]
    177179    public function offsetGet($offset)
    178180    {
     
    201203     * {@inheritdoc}
    202204     */
     205    #[\ReturnTypeWillChange]
    203206    public function offsetSet($offset, $value)
    204207    {
     
    209212     * {@inheritdoc}
    210213     */
     214    #[\ReturnTypeWillChange]
    211215    public function offsetUnset($offset)
    212216    {
  • secured-wp/tags/1.7/vendor/scssphp/scssphp/src/Parser.php

    r2576070 r2636555  
    15811581                        list($line, $column) = $this->getSourcePosition($this->count);
    15821582                        $file = $this->sourceName;
    1583                         $this->logger->warn("Unterminated interpolations in multiline comments are deprecated and will be removed in ScssPhp 2.0, in \"$file\", line $line, column $column.", true);
     1583                        if (!$this->discardComments) {
     1584                            $this->logger->warn("Unterminated interpolations in multiline comments are deprecated and will be removed in ScssPhp 2.0, in \"$file\", line $line, column $column.", true);
     1585                        }
    15841586                        $comment[] = substr($this->buffer, $this->count, 2);
    15851587
  • secured-wp/tags/1.7/vendor/scssphp/scssphp/src/Version.php

    r2576070 r2636555  
    2020class Version
    2121{
    22     const VERSION = '1.6.0';
     22    const VERSION = '1.8.1';
    2323}
  • secured-wp/trunk/classes/Controllers/LoginCheck.php

    r2577925 r2636555  
    1414use WPSEC\Helpers\{
    1515    NotifyAdmin,
    16     OutOfBondEmail,
     16    OutOfBandEmail,
    1717};
    1818use WPSEC\Controllers\{
     
    3737         * Checks the user login credentials
    3838         *
    39          * TODO: change the loging in user check - set proper priorities
     39         * TODO: change the logging in user check - set proper priorities
    4040         *
    4141         * 1. Checks if user is locked
     
    5555        public static function check( $user, $username, $password ) {
    5656
     57            /**
     58             * If neither of modules is enabled - return the user
     59             */
    5760            if ( (bool) \WPSEC\Controllers\Modules\LoginAttempts::getGlobalSettingsValue()
    5861                &&
     
    187190         * @return void
    188191         *
    189          * @since
     192         * @since $VERSION
    190193         */
    191194        public static function loginValidateOob() {
     
    207210        public static function setRememberMe() {
    208211
    209             if ( isset( $_POST['rememberme'] ) && ! empty( $_POST['rememberme'] ) ) {
     212            if ( isset( $_POST['rememberme'] ) && ! empty( $_POST['rememberme'] ) ) { // @codingStandardsIgnoreLine - Nonce check is not needed
    210213                RememberMe::setRememberMe( User::getUser()->ID );
    211214                User::setLoggedInDevice( RememberMe::getDevice() );
     
    214217
    215218        /**
    216          * Checks Out of bond email link and logging the user if passed
     219         * Checks Out of band email link and logging the user if passed
    217220         *
    218221         * @param bool $secondPass - first pass comes from e-mail (link), second pass comes from WP form itself.
     
    240243                            $wpsOtp = (string) \sanitize_text_field( \wp_unslash( $params['wps_otp'] ) );
    241244
    242                             $nonceName = OutOfBondEmail::getNonceName();
     245                            $nonceName = OutOfBandEmail::getNonceName();
    243246
    244247                            if ( isset( $params[ $nonceName ] ) && ! empty( $params[ $nonceName ] ) ) {
    245                                 if ( ! \wp_verify_nonce( \sanitize_text_field( \wp_unslash( $params[ $nonceName ] ) ), OutOfBondEmail::getNonceNamePrefix() . $userId ) ) {
     248                                if ( ! \wp_verify_nonce( \sanitize_text_field( \wp_unslash( $params[ $nonceName ] ) ), OutOfBandEmail::getNonceNamePrefix() . $userId ) ) {
    246249                                    exit();
    247250                                }
    248251
    249252                                // check transient.
    250                                 $dataTimeout = \get_option( '_transient_timeout_' . OutOfBondEmail::getTransientPrefix() . ( (string) $userId ) );
     253                                $dataTimeout = \get_option( '_transient_timeout_' . OutOfBandEmail::getTransientPrefix() . ( (string) $userId ) );
    251254                                if ( $dataTimeout > time() ) {
    252                                     if ( OutOfBondEmail::validateUserOOB( $userId, $wpsOtp ) ) {
     255                                    if ( OutOfBandEmail::validateUserOOB( $userId, $wpsOtp ) ) {
    253256
    254257                                        if ( ! $secondPass ) {
     
    257260                                        }
    258261                                        \wp_clear_auth_cookie();
    259                                         OutOfBondEmail::deleteTransient( $userId );
     262                                        OutOfBandEmail::deleteTransient( $userId );
    260263                                        \wp_set_current_user( $userId );
    261264                                        \wp_set_auth_cookie( $userId );
  • secured-wp/trunk/classes/Controllers/Modules/Login.php

    r2576070 r2636555  
    7979            \add_action( 'plugins_loaded', [ __CLASS__, 'pluginsLoaded' ], 9999 );
    8080            \add_action( 'wp_loaded', [ __CLASS__, 'wpLoaded' ] );
     81            \add_action( 'wp_redirect', [ __CLASS__, 'wpRedirect' ], 10, 2 );
    8182            \add_action( 'setup_theme', [ __CLASS__, 'setupTheme' ], 1 );
    8283
     
    567568
    568569        /**
    569          * Check the current url and changes it if necessary
    570          *
    571          * @since 1.0.0
    572          *
    573          * @param string $url - the url of the site.
    574          * @param mixed  $scheme - the URL scheme.
    575          *
    576          * @return string
    577          */
    578         public static function filterWpLoginPhp( $url, $scheme = null ): string {
    579 
    580             if ( false !== strpos( $url, 'wp-login.php?action=postpass' ) ) {
     570         * Called on wp_redirect action. Checks the URL string, and filters it accordingly if wp-login.php is presented (substitute it with the new slug)
     571         *
     572         * @param string  $url - The URL to which WP is trying to redirect to.
     573         * @param integer $status - Number code of the status.
     574         *
     575         * @return string
     576         *
     577         * @since 1.6
     578         */
     579        public static function wpRedirect( string $url, int $status ): string {
     580
     581            if ( strpos( $url, 'https://wordpress.com/wp-login.php' ) !== false ) {
    581582                return $url;
    582583            }
    583584
    584             if ( false !== strpos( $url, 'wp-login.php' ) && false === strpos( (string) \wp_get_referer(), 'wp-login.php' ) ) {
    585 
    586                 if ( \is_ssl() ) {
    587 
    588                     $scheme = 'https';
    589 
    590                 }
    591 
    592                 $args = explode( '?', $url );
    593 
    594                 if ( isset( $args[1] ) ) {
    595 
    596                     parse_str( $args[1], $args );
    597 
    598                     if ( isset( $args['login'] ) ) {
    599                         $args['login'] = rawurlencode( $args['login'] );
    600                     }
    601 
    602                     $url = \add_query_arg( $args, self::newLoginUrl( $scheme ) );
    603 
    604                 } else {
    605 
    606                     $url = self::newLoginUrl( $scheme );
    607 
    608                 }
    609             }
    610 
    611             return $url;
    612 
     585            return self::filterWpLoginPhp( $url );
    613586        }
    614587
     
    761734
    762735        /**
     736         * Checks the current url and changes it if necessary
     737         *
     738         * @since 1.0.0
     739         *
     740         * @param string $url - the url of the site.
     741         * @param mixed  $scheme - the URL scheme.
     742         *
     743         * @return string
     744         */
     745        private static function filterWpLoginPhp( $url, $scheme = null ): string {
     746
     747            if ( false !== strpos( $url, 'wp-login.php?action=postpass' ) ) {
     748                return $url;
     749            }
     750
     751            if ( false !== strpos( $url, 'wp-login.php' ) && false === strpos( (string) \wp_get_referer(), 'wp-login.php' ) ) {
     752
     753                if ( \is_ssl() ) {
     754
     755                    $scheme = 'https';
     756
     757                }
     758
     759                $args = explode( '?', $url );
     760
     761                if ( isset( $args[1] ) ) {
     762
     763                    parse_str( $args[1], $args );
     764
     765                    if ( isset( $args['login'] ) ) {
     766                        $args['login'] = rawurlencode( $args['login'] );
     767                    }
     768
     769                    $url = \add_query_arg( $args, self::newLoginUrl( $scheme ) );
     770
     771                } else {
     772
     773                    $url = self::newLoginUrl( $scheme );
     774
     775                }
     776            }
     777
     778            return $url;
     779        }
     780
     781        /**
    763782         * Returns the wpLogin status
    764783         *
  • secured-wp/trunk/classes/Controllers/Modules/RememberMe.php

    r2576070 r2636555  
    247247
    248248            \delete_transient(
    249                 self::$transientPrefix . md5( $device ) . '_' . $userId,
     249                self::$transientPrefix . md5( $device ) . '_' . $userId
    250250            );
    251251        }
  • secured-wp/trunk/classes/Controllers/Modules/XMLRPCprevents.php

    r2576070 r2636555  
    1313
    1414use WPSEC\Helpers\WPHelper;
    15 use WPSEC\Validators\Validator;
    1615
    1716defined( 'ABSPATH' ) || exit; // Exit if accessed directly.
  • secured-wp/trunk/classes/Controllers/User.php

    r2579465 r2636555  
    616616         * @return string
    617617         *
    618          * @since
     618         * @since 1.7
    619619         */
    620620        public static function getStatus( $user = null ): string {
  • secured-wp/trunk/classes/Secured.php

    r2579465 r2636555  
    2727};
    2828use WPSEC\Validators\Validator;
     29use WPSEC\Views\UserProfile;
    2930
    3031if ( ! class_exists( 'WPSEC\Secured' ) ) {
     
    6162         * @since 1.0.0
    6263         *
    63          * @param array $links - Gloabal links array.
     64         * @param array $links - Global links array.
    6465         *
    6566         * @return array
     
    9192                /* translators: %1$s: PHP version */
    9293                    \esc_html__( 'You need to update your PHP version to %1s.', 'secured-wp' ),
    93                     WPSEC_REQUIRED_PHP_VERSION // @codingStandardsIgnoreLine - that is defined constatnt no need to escape it
     94                    WPSEC_REQUIRED_PHP_VERSION // @codingStandardsIgnoreLine - that is defined constant no need to escape it
    9495                );
    9596                ?>
     
    112113                /* translators: %1$s: WP version */
    113114                    \esc_html__( 'You need to update your WP version to %1s.', 'secured-wp' ),
    114                 WPSEC_REQUIRED_WP_VERSION // @codingStandardsIgnoreLine - that is defined constatnt no need to escape it
     115                    WPSEC_REQUIRED_WP_VERSION // @codingStandardsIgnoreLine - that is defined constant no need to escape it
    115116                );
    116117                ?>
     
    170171         * Returns the status of delete data upon uninstall
    171172         *
    172          * @since 1.0.0
    173          *
    174173         * @param mixed $blogId - WP blog ID.
    175174         *
    176175         * @return mixed
     176         *
     177         * @since 1.0.0
    177178         */
    178179        public static function isDeleteDataEnabled( $blogId = '' ) {
     
    220221
    221222        /**
     223         * Shows the content for user settings when short code is used
     224         *
     225         * @return void - the parsed HTML.
     226         *
     227         * @since 1.6
     228         */
     229        public static function settingsShortCode() {
     230
     231            if ( User::isCurrentlyLogged() ) {
     232                $user = User::getUser();
     233                ob_start();
     234                UserProfile::userEditProfile( $user );
     235                $content = ob_get_clean();
     236                echo $content;  // @codingStandardsIgnoreLine - All output must be escaped warning
     237            } else {
     238                ?>
     239                <h2><?php echo \esc_html__( 'You must be logged in to see this content', 'secured-wp' ); ?></h2>
     240                <?php
     241            }
     242        }
     243
     244        /**
    222245         * Inits all the hooks the plugin will use
    223246         *
    224          * @since 1.0.0
    225          *
    226          * @return void
     247         * @return void
     248         *
     249         * @since 1.0.0
    227250         */
    228251        private static function initHooks() {
     
    237260             */
    238261            \add_action( 'login_form_confirm_oob', [ 'WPSEC\\Controllers\\LoginCheck', 'loginValidateOob' ], 1 );
     262
     263            /**
     264             * Adds shortcode - that gives the ability to create our own page with user settings
     265             */
     266            \add_shortcode( 'wps_custom_settings', [ __CLASS__, 'settingsShortCode' ] );
    239267
    240268            /**
     
    276304                 * Adds ajax request for sending the OOB
    277305                 */
    278                 \add_action( 'wp_ajax_nopriv_send_oob', [ 'WPSEC\\Helpers\\OutOfBondEmail', 'sendOOBEmail' ] );
    279                 \add_action( 'wp_ajax_send_oob', [ 'WPSEC\\Helpers\\OutOfBondEmail', 'sendOOBEmail' ] );
     306                \add_action( 'wp_ajax_nopriv_send_oob', [ 'WPSEC\\Helpers\\OutOfBandEmail', 'sendOOBEmail' ] );
     307                \add_action( 'wp_ajax_send_oob', [ 'WPSEC\\Helpers\\OutOfBandEmail', 'sendOOBEmail' ] );
    280308            }
    281309
     
    308336            /**
    309337             * If user is logged in and there is woocommerce installed and the method is enabled,
    310              * we gona need the AJAX methods available.
     338             * we gonna need the AJAX methods available.
    311339             */
    312340            if ( User::isCurrentlyLogged() ) {
    313                 if ( class_exists( 'WooCommerce' ) ) {
    314                     if ( ! (bool) \WPSEC\Controllers\Modules\TwoFASettings::getGlobalSettingsValue() ) {
    315                         // AJAX request for the user - do we need this globally for the Admin Part of the WP ?.
    316                         AjaxRequests::initAdmin();
    317                     }
     341                // if ( class_exists( 'WooCommerce' ) ) {
     342                if ( ! (bool) \WPSEC\Controllers\Modules\TwoFASettings::getGlobalSettingsValue() ) {
     343                    // AJAX request for the user - do we need this globally for the Admin Part of the WP ?.
     344                    AjaxRequests::initAdmin();
    318345                }
    319             }
    320         }
    321 
    322         /**
    323          * Conditionally add assets only when they are necessary
    324          *
    325          * @since 1.0.0
    326          *
    327          * @return void
     346                // }
     347            }
     348        }
     349
     350        /**
     351         * Conditionally adds assets only when they are necessary
     352         *
     353         * @return void
     354         *
     355         * @since 1.0.0
    328356         */
    329357        private static function addAssets() {
  • secured-wp/trunk/classes/Views/LoginForms.php

    r2578321 r2636555  
    1212namespace WPSEC\Views;
    1313
     14use WPSEC\Helpers\TOTPHelper;
    1415use WPSEC\{
    1516    Controllers\User,
    1617    Controllers\Modules\TwoFASettings,
    17     Helpers\OutOfBondEmail
     18    Helpers\OutOfBandEmail
    1819};
    19 use OTPHP\TOTP;
    2020
    2121defined( 'ABSPATH' ) || exit; // Exit if accessed directly.
     
    107107            if ( ! User::isTotpUserEnabled() ) {
    108108                echo \esc_html( \get_bloginfo( 'name' ) );
    109 
    110                 $otp = TOTP::create( User::getUserTotp() );
    111 
    112                 $otp->setLabel(
    113                     \get_bloginfo( 'name' )
    114                 );
    115                 $grCodeUri = $otp->getQrCodeUri(
    116                     'https://api.qrserver.com/v1/create-qr-code/?data=[DATA]&size=200x200&ecc=M',
    117                     '[DATA]'
    118                 );
    119109                ?>
    120                 <div style='width:100%;margin: 0 auto; text-align:center;'><img src='<?php echo \esc_attr( $grCodeUri ); ?>'></div>
     110                <div style='width:100%;margin: 0 auto; text-align:center;'><img src='<?php echo \esc_attr( TOTPHelper::generateQRSVGData() ); ?>' width="100%"></div>
    121111                <?php
    122112                echo \esc_html__( 'Scan above with your favorite Authenticator Application and enter the code below or add the following code:', 'secured-wp' );
    123                 echo '<div><strong>' . \esc_html( $otp->getSecret() ) . '</strong></div>';
     113                echo '<div><strong>' . \esc_html( User::getUserTotp() ) . '</strong></div>';
    124114            } else {
    125115                echo \esc_html__( 'Open the Authenticator Application on your phone and enter the code for ' . \get_bloginfo( 'name' ), 'secured-wp' );
     
    198188                <input type="hidden" name="wps_otp" id="wps_otp" value="<?php echo \esc_attr( \wp_unslash( $_GET['wps_otp'] ) ); ?>" />
    199189                <input type="hidden" name="user_id" id="wps_otp" value="<?php echo \esc_attr( \wp_unslash( $_GET['user_id'] ) ); ?>" />
    200             <?php \wp_nonce_field( OutOfBondEmail::getNonceNamePrefix() . \wp_unslash( $_GET['user_id'] ), OutOfBondEmail::getNonceName() ); ?>
     190            <?php \wp_nonce_field( OutOfBandEmail::getNonceNamePrefix() . \wp_unslash( $_GET['user_id'] ), OutOfBandEmail::getNonceName() ); ?>
    201191            <div>
    202192                <p>
     
    271261
    272262        /**
    273          * Adds Out of bond link to the login form
     263         * Adds Out of Band link to the login form
    274264         *
    275265         * @since 1.0.0
     
    284274                ?>
    285275            <div style="clear: both;" id="wsc-oob-wrapper">
    286                 <a href="#" id="send-oob-mail"><?php echo \esc_html__( 'Send me out of bond email instead', 'secured-wp' ); ?></a>
     276                <a href="#" id="send-oob-mail"><?php echo \esc_html__( 'Send me out of band email instead', 'secured-wp' ); ?></a>
    287277            </div>
    288278            <script>
  • secured-wp/trunk/classes/Views/SettingsTabs.php

    r2576070 r2636555  
    240240                    </tr>
    241241                    <tr>
    242                         <th scope="row"><?php echo \esc_html__( 'Out of bond e-mail ', 'secured-wp' ); ?></th>
     242                        <th scope="row"><?php echo \esc_html__( 'Out of band e-mail ', 'secured-wp' ); ?></th>
    243243                        <td>
    244244                            <label for="<?php echo \esc_attr( WPSEC_PLUGIN_SECURED_2FA_OOB_VAR_NAME ); ?>">
  • secured-wp/trunk/classes/Views/UserProfile.php

    r2579465 r2636555  
    1414defined( 'ABSPATH' ) || exit; // Exit if accessed directly.
    1515
    16 use OTPHP\TOTP;
    1716use WPSEC\Controllers\{
    1817    User,
    1918    Modules\RememberMe,
    2019};
     20use WPSEC\Helpers\TOTPHelper;
    2121
    2222if ( ! class_exists( 'WPSEC\Views\UserProfile' ) ) {
     
    132132
    133133                </table>
    134                 <div class="tablenav">
     134                <div class="tablenav" style="overflow:hidden;">
    135135                    <div class="alignright">
    136136                    <?php
    137                     \submit_button(
    138                         __( 'Remove all logged in devices', 'secured-wp' ),
    139                         'delete',
    140                         'remove-all-logged-devices',
    141                         false
    142                     );
     137                    if ( function_exists( 'submit_button' ) ) {
     138                        \submit_button(
     139                            __( 'Remove all logged in devices', 'secured-wp' ),
     140                            'delete',
     141                            'remove-all-logged-devices',
     142                            false
     143                        );
     144                    } else {
     145                        ?>
     146                    <input type="submit" name="remove-all-logged-devices" id="remove-all-logged-devices" class="button delete" value="Remove all logged in devices">
     147                        <?php
     148                        self::deleteQRCodeJS();
     149                    }
    143150                    ?>
    144151                    </div>
    145152                </div>
    146                 <hr>
     153                <hr style="clear:both; margin-top:5px;">
    147154                <?php
    148155                if ( \current_user_can( 'edit_user', User::getUser()->ID ) && ! (bool) User::isTwoFaUserExcluded() ) {
     
    166173                ?>
    167174            <h3><?php echo \esc_html__( 'QR code for the TOTP 2FA login', 'secured-wp' ); ?></h3>
    168                 <?php
    169                 $otp = TOTP::create( User::getUserTotp() );
    170 
    171                 $otp->setLabel(
    172                     \get_bloginfo( 'name' )
    173                 );
    174                 $grCodeUri = $otp->getQrCodeUri(
    175                     'https://api.qrserver.com/v1/create-qr-code/?data=[DATA]&size=200x200&ecc=M',
    176                     '[DATA]'
    177                 );
    178                 ?>
    179             <div style='width:100%;margin: 0 auto; text-align:center;'><img src='<?php echo \esc_attr( $grCodeUri ); ?>'></div>
     175
     176            <div style='width:100%;margin: 0 auto; text-align:center;'><img src='<?php echo \esc_attr( TOTPHelper::generateQRSVGData() ); ?>'></div>
    180177            <div><?php echo \esc_html__( 'Or use the following key, by entering it directly in you preferable authentication application:', 'secured-wp' ); ?></div>
    181178            <div><strong><?php echo \esc_html( $otp->getSecret() ); ?></strong></div>
    182             <div class="tablenav">
     179            <div class="tablenav" style="overflow:hidden;">
    183180                <div class="alignleft">
    184181                <?php
     
    205202                </div>
    206203            </div>
     204            <hr style="clear:both; margin-top:5px;">
    207205                <?php
    208206            }
     
    316314            ?>
    317315        <script>
    318             ( function( jQuery ) {
    319                 jQuery('.alignleft').on('click', '#regenerate-qr-code', function(e) {
    320                     e.preventDefault();
    321                     var ajaxurl = "<?php echo \esc_url( admin_url( 'admin-ajax.php' ) ); ?>"
    322                     var deleteData = {
    323                         'action': 'wps_delete_qr',
    324                         'user': '<?php echo \esc_attr( User::getUser()->ID ); ?>',
    325                         'nonce': '<?php echo \esc_attr( \wp_create_nonce( 'wp-secured-wps_delete_qr-ajax-nonce' ) ); ?>',
    326                     };
    327 
    328                     let that = this;
    329 
    330                     jQuery.ajax({
    331                         type: "post",
    332                         dataType: "json",
    333                         url: ajaxurl,
    334                         data: deleteData,
    335                         success: function( msg ) {
    336                             if ( 'success' == msg['result'] ) {
    337                                 location.reload(); ;
    338                             }
    339                         }
    340                     });
    341                 });
    342             }( jQuery ) );
     316            var qrRegenerate = document.getElementById('regenerate-qr-code');
     317            qrRegenerate.addEventListener("click", function(e) {
     318                e.preventDefault();
     319                var request = new XMLHttpRequest();
     320
     321                request.open('POST', '<?php echo \esc_url( \admin_url( 'admin-ajax.php' ) ); ?>', true);
     322                request.setRequestHeader('Content-Type', 'application/x-www-form-urlencoded;');
     323                request.responseType = 'json';
     324                request.onload = function () {
     325                    if (this.status >= 200 && this.status < 400) {
     326                        location.reload();
     327                    } else {
     328                        // If fail
     329                        console.log(this.response);
     330                    }
     331                };
     332                request.onerror = function() {
     333                    console.log('Connection error');
     334                };
     335
     336                var deleteData = {
     337                    "action": "wps_delete_qr",
     338                    "user": "<?php echo \esc_attr( User::getUser()->ID ); ?>",
     339                    "nonce": "<?php echo \esc_attr( \wp_create_nonce( 'wp-secured-wps_delete_qr-ajax-nonce' ) ); ?>",
     340                };
     341
     342                request.send("action=wps_delete_qr&user=<?php echo \esc_attr( User::getUser()->ID ); ?>&nonce=<?php echo \esc_attr( \wp_create_nonce( 'wp-secured-wps_delete_qr-ajax-nonce' ) ); ?>");
     343            }, false);
     344
    343345        </script>
    344346            <?php
  • secured-wp/trunk/classes/Views/UsersList.php

    r2578323 r2636555  
    5757         * @var string
    5858         *
    59          * @since
     59         * @since 1.7
    6060         */
    6161        private static $changeLockedBulkActionName = 'change-to-locked';
     
    6666         * @var string
    6767         *
    68          * @since
     68         * @since 1.7
    6969         */
    7070        private static $changeUnLockedBulkActionName = 'change-to-unlocked';
     
    7575         * @var string
    7676         *
    77          * @since
     77         * @since 1.7
    7878         */
    7979        private static $changeExcludeTwoFaBulkActionName = 'exclude-2fa';
     
    8484         * @var string
    8585         *
    86          * @since
     86         * @since 1.7
    8787         */
    8888        private static $changeIncludeTwoFaBulkActionName = 'include-2fa';
     
    127127            }
    128128
     129            // wpmu_users_columns
     130            // manage_users - network_sortable_columns
     131
    129132            /**
    130133             * Show logged in column
     
    136139            if ( WPHelper::isMultisite() ) {
    137140                \add_filter( 'wpmu_users_columns', [ __CLASS__, 'addUsersLoggedColumn' ] );
     141                \add_filter( 'manage_users-network_sortable_columns', [ __CLASS__, 'addUsersLoggedColumn' ] );
    138142            }
    139143
  • secured-wp/trunk/constants.php

    r2579464 r2636555  
    1414}
    1515
    16 define( 'WPSEC_REQUIRED_PHP_VERSION', '7.2' );
     16define( 'WPSEC_REQUIRED_PHP_VERSION', '7.3' );
    1717define( 'WPSEC_REQUIRED_WP_VERSION', '5.0' );
    18 define( 'WPSEC_PLUGIN_SECURED_VERSION', '1.5' );
     18define( 'WPSEC_PLUGIN_SECURED_VERSION', '1.7' );
    1919define( 'WPSEC_PLUGIN_SECURED_NAME', 'Secured WP' );
    2020define( 'WPSEC_PLUGIN_SECURED_SLUG', 'secured-wp' );
  • secured-wp/trunk/languages/secured-wp.pot

    r2577909 r2636555  
    11# Copyright (C) 2021 wp-secured
    2 # This file is distributed under the same license as the Secured WP plugin.
     2# This file is distributed under the GPL-2.0+.
    33msgid ""
    44msgstr ""
    5 "Project-Id-Version: Secured WP 1.1\n"
     5"Project-Id-Version: Secured WP 1.6\n"
    66"Report-Msgid-Bugs-To: https://wordpress.org/support/plugin/secured-wp\n"
    77"Last-Translator: FULL NAME <EMAIL@ADDRESS>\n"
     
    1010"Content-Type: text/plain; charset=UTF-8\n"
    1111"Content-Transfer-Encoding: 8bit\n"
    12 "POT-Creation-Date: 2021-08-04T14:05:08+03:00\n"
     12"POT-Creation-Date: 2021-08-15T09:21:29+00:00\n"
    1313"PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n"
    14 "X-Generator: WP-CLI 2.4.0\n"
    15 "X-Domain: wp-secured\n"
     14"X-Generator: WP-CLI 2.5.0\n"
     15"X-Domain: secured-wp\n"
    1616
    1717#. Plugin Name of the plugin
     
    3131msgid "wp-secured"
    3232msgstr ""
     33
     34#: classes/Controllers/LoginCheck.php:78
     35msgid "<strong>Error</strong>: Too soon."
     36msgstr ""
     37
     38#: classes/Controllers/LoginCheck.php:102
     39msgid "<strong>Error</strong>: Too many attempts."
     40msgstr ""
     41
     42#: classes/Controllers/LoginCheck.php:174
     43msgid "Invalid code provided"
     44msgstr ""
     45
     46#: classes/Controllers/Modules/Login.php:396
     47msgid "This feature is not enabled."
     48msgstr ""
     49
     50#: classes/Controllers/Modules/Login.php:447
     51msgid "Nothing to see here"
     52msgstr ""
     53
     54#: classes/Controllers/Modules/Login.php:682
     55msgid "Login"
     56msgstr ""
     57
     58#: classes/Controllers/Modules/Login.php:699
     59msgid "New login slug"
     60msgstr ""
     61
     62#: classes/Controllers/Modules/Login.php:703
     63msgid "Redirect original login"
     64msgstr ""
     65
     66#: classes/Controllers/Modules/Login.php:759
     67msgid "Hides the standard wp-login.php with your personal slug of choice. Redirects the original login to slug of your choice"
     68msgstr ""
     69
     70#: classes/Controllers/Modules/LoginAttempts.php:235
     71msgid "Login attempts"
     72msgstr ""
     73
     74#: classes/Controllers/Modules/LoginAttempts.php:252
     75#: classes/Views/SettingsTabs.php:119
     76msgid "Login Attempts"
     77msgstr ""
     78
     79#: classes/Controllers/Modules/LoginAttempts.php:256
     80#: classes/Controllers/Modules/RememberMe.php:351
     81#: classes/Views/SettingsTabs.php:127
     82msgid "Lock time"
     83msgstr ""
     84
     85#: classes/Controllers/Modules/LoginAttempts.php:257
     86msgid " mins."
     87msgstr ""
     88
     89#: classes/Controllers/Modules/LoginAttempts.php:294
     90msgid "Counts incorect login attempts and locks the user - use standard user menu to check locked users."
     91msgstr ""
     92
     93#: classes/Controllers/Modules/RememberMe.php:334
     94msgid "Remember Devices"
     95msgstr ""
     96
     97#: classes/Controllers/Modules/RememberMe.php:352
     98msgid " days."
     99msgstr ""
     100
     101#: classes/Controllers/Modules/RememberMe.php:405
     102msgid "When enabled, if user checks remember me on login, the device will be stored and the user wont be asked for credentials for the given amount of time."
     103msgstr ""
     104
     105#: classes/Controllers/Modules/TwoFASettings.php:189
     106msgid "2FA settings"
     107msgstr ""
     108
     109#: classes/Controllers/Modules/TwoFASettings.php:206
     110msgid "TOTP enabled"
     111msgstr ""
     112
     113#: classes/Controllers/Modules/TwoFASettings.php:207
     114#: classes/Controllers/Modules/TwoFASettings.php:211
     115#: classes/Helpers/Information/ModuleInformation.php:49
     116msgid "true"
     117msgstr ""
     118
     119#: classes/Controllers/Modules/TwoFASettings.php:207
     120#: classes/Controllers/Modules/TwoFASettings.php:211
     121#: classes/Helpers/Information/ModuleInformation.php:49
     122msgid "false"
     123msgstr ""
     124
     125#: classes/Controllers/Modules/TwoFASettings.php:210
     126msgid "OOB enabled"
     127msgstr ""
     128
     129#: classes/Controllers/Modules/TwoFASettings.php:266
     130msgid "Enables 2FA. Next time, when user logins s/he will be asked to add the site to Authenticator application of their choice, and from now on they must provide code from that App in order to login."
     131msgstr ""
     132
     133#: classes/Controllers/Modules/XMLRPCprevents.php:62
     134msgid "XML-RPC settings"
     135msgstr ""
     136
     137#: classes/Controllers/Modules/XMLRPCprevents.php:108
     138msgid "Disables XML-RPC. By default WordPress has that enabled - this is potentially security risk - that will disable XML-RPC on your site completely"
     139msgstr ""
     140
     141#: classes/Controllers/User.php:622
     142msgid "2FA enabled: YES"
     143msgstr ""
     144
     145#: classes/Controllers/User.php:623
     146msgid "TOTP enabled: NO"
     147msgstr ""
     148
     149#: classes/Controllers/User.php:627
     150msgid "2FA enabled: EXCLUDED"
     151msgstr ""
     152
     153#: classes/Controllers/User.php:631
     154msgid "TOTP enabled: YES"
     155msgstr ""
     156
     157#: classes/Helpers/Information/ModuleInformation.php:49
     158msgid "Disabled: "
     159msgstr ""
     160
     161#: classes/Helpers/NotifyAdmin.php:39
     162msgid "Maximum number of unsuccessful login attempts reached"
     163msgstr ""
     164
     165#: classes/Helpers/OutOfBandEmail.php:93
     166msgid "One time login link"
     167msgstr ""
     168
     169#: classes/Helpers/OutOfBandEmail.php:128
     170msgid "Out of bond email link"
     171msgstr ""
     172
     173#: classes/Secured.php:70
     174msgid "Settings"
     175msgstr ""
     176
     177#. translators: %1$s: PHP version
     178#: classes/Secured.php:93
     179msgid "You need to update your PHP version to %1s."
     180msgstr ""
     181
     182#: classes/Secured.php:98
     183#: classes/Secured.php:119
     184msgid "Actual version is:"
     185msgstr ""
     186
     187#. translators: %1$s: WP version
     188#: classes/Secured.php:114
     189msgid "You need to update your WP version to %1s."
     190msgstr ""
     191
     192#: classes/Secured.php:239
     193msgid "You must be logged in to see this content"
     194msgstr ""
     195
     196#: classes/Validators/Validator.php:64
     197#: classes/Validators/Validator.php:94
     198msgid "No rules are set - nothing to test against"
     199msgstr ""
     200
     201#: classes/Validators/Validator.php:72
     202msgid "Variable is not set"
     203msgstr ""
     204
     205#: classes/Validators/Validator.php:126
     206msgid "Variable is not valid e-mail"
     207msgstr ""
     208
     209#: classes/Validators/Validator.php:191
     210msgid "Variable is not integer"
     211msgstr ""
     212
     213#: classes/Validators/Validator.php:195
     214#: classes/Validators/Validator.php:211
     215msgid "Variable is not positive integer!"
     216msgstr ""
     217
     218#: classes/Validators/Validator.php:214
     219msgid "Variable is not in given range"
     220msgstr ""
     221
     222#: classes/Views/AdminSettingsView.php:104
     223msgid "Information"
     224msgstr ""
     225
     226#: classes/Views/AdminSettingsView.php:110
     227msgid "Provides Security for WP sites"
     228msgstr ""
     229
     230#: classes/Views/AdminSettingsView.php:115
     231msgid "Version"
     232msgstr ""
     233
     234#: classes/Views/AdminSettingsView.php:119
     235msgid "Delete data on plugin uninstall"
     236msgstr ""
     237
     238#: classes/Views/AdminSettingsView.php:122
     239msgid "That setting is global"
     240msgstr ""
     241
     242#: classes/Views/AdminSettingsView.php:126
     243msgid "Modules Information"
     244msgstr ""
     245
     246#: classes/Views/AdminSettingsView.php:137
     247#: classes/Views/AdminSettingsView.php:155
     248msgid "Save Changes"
     249msgstr ""
     250
     251#: classes/Views/AdminSettingsView.php:163
     252msgid "Restore Default Plugin Settings"
     253msgstr ""
     254
     255#: classes/Views/AdminSettingsView.php:177
     256msgid "Are you sure you want to restore the defaults? All settings will be overridden"
     257msgstr ""
     258
     259#: classes/Views/AdminSettingsView.php:182
     260msgid "Are you sure you want to restore the defaults? All module settings will be overridden"
     261msgstr ""
     262
     263#: classes/Views/LoginForms.php:122
     264msgid "Scan above with your favorite Authenticator Application and enter the code below or add the following code:"
     265msgstr ""
     266
     267#: classes/Views/LoginForms.php:125
     268msgid "Open the Authenticator Application on your phone and enter the code for "
     269msgstr ""
     270
     271#: classes/Views/LoginForms.php:129
     272msgid "Authentication Code:"
     273msgstr ""
     274
     275#: classes/Views/LoginForms.php:135
     276#: classes/Views/LoginForms.php:209
     277msgid "Log In"
     278msgstr ""
     279
     280#: classes/Views/LoginForms.php:203
     281msgid "Click the button to finish the login."
     282msgstr ""
     283
     284#: classes/Views/LoginForms.php:236
     285msgid "You have logged in successfully."
     286msgstr ""
     287
     288#: classes/Views/LoginForms.php:286
     289msgid "Send me out of bond email instead"
     290msgstr ""
     291
     292#: classes/Views/SettingsTabs.php:52
     293msgid "Login redirection Settings"
     294msgstr ""
     295
     296#: classes/Views/SettingsTabs.php:55
     297msgid "Disable Login Redirection"
     298msgstr ""
     299
     300#: classes/Views/SettingsTabs.php:56
     301#: classes/Views/SettingsTabs.php:111
     302#: classes/Views/SettingsTabs.php:173
     303#: classes/Views/SettingsTabs.php:226
     304#: classes/Views/SettingsTabs.php:281
     305msgid "Description:"
     306msgstr ""
     307
     308#: classes/Views/SettingsTabs.php:58
     309#: classes/Views/SettingsTabs.php:114
     310#: classes/Views/SettingsTabs.php:176
     311#: classes/Views/SettingsTabs.php:229
     312#: classes/Views/SettingsTabs.php:284
     313msgid "These settings are blog related (multisite)"
     314msgstr ""
     315
     316#: classes/Views/SettingsTabs.php:63
     317msgid "New Login redirection slug"
     318msgstr ""
     319
     320#: classes/Views/SettingsTabs.php:66
     321msgid "New login redirection slug"
     322msgstr ""
     323
     324#: classes/Views/SettingsTabs.php:71
     325#: classes/Views/SettingsTabs.php:74
     326msgid "Redirect original login to"
     327msgstr ""
     328
     329#: classes/Views/SettingsTabs.php:79
     330#: classes/Views/SettingsTabs.php:141
     331#: classes/Views/SettingsTabs.php:195
     332#: classes/Views/SettingsTabs.php:250
     333#: classes/Views/SettingsTabs.php:289
     334msgid "Default Settings"
     335msgstr ""
     336
     337#: classes/Views/SettingsTabs.php:83
     338#: classes/Views/SettingsTabs.php:145
     339#: classes/Views/SettingsTabs.php:199
     340#: classes/Views/SettingsTabs.php:254
     341#: classes/Views/SettingsTabs.php:293
     342msgid "Restore Module Default Settings"
     343msgstr ""
     344
     345#: classes/Views/SettingsTabs.php:89
     346#: classes/Views/SettingsTabs.php:151
     347#: classes/Views/SettingsTabs.php:205
     348msgid "This will restore module settings to defaults."
     349msgstr ""
     350
     351#: classes/Views/SettingsTabs.php:107
     352msgid "Login Attempts Settings"
     353msgstr ""
     354
     355#: classes/Views/SettingsTabs.php:110
     356msgid "Disable Login Attempts"
     357msgstr ""
     358
     359#: classes/Views/SettingsTabs.php:136
     360msgid "How many minutes to lock the user"
     361msgstr ""
     362
     363#: classes/Views/SettingsTabs.php:169
     364msgid "Remember Device Settings"
     365msgstr ""
     366
     367#: classes/Views/SettingsTabs.php:172
     368msgid "Disable Remember Devices"
     369msgstr ""
     370
     371#: classes/Views/SettingsTabs.php:181
     372msgid "Remember Device Time"
     373msgstr ""
     374
     375#: classes/Views/SettingsTabs.php:190
     376msgid "How many days remember device"
     377msgstr ""
     378
     379#: classes/Views/SettingsTabs.php:222
     380msgid "2FA Settings"
     381msgstr ""
     382
     383#: classes/Views/SettingsTabs.php:225
     384msgid "Disable 2FA"
     385msgstr ""
     386
     387#: classes/Views/SettingsTabs.php:234
     388msgid "TOTP "
     389msgstr ""
     390
     391#: classes/Views/SettingsTabs.php:242
     392msgid "Out of bond e-mail "
     393msgstr ""
     394
     395#: classes/Views/SettingsTabs.php:260
     396#: classes/Views/SettingsTabs.php:299
     397msgid "This will restore plugin settings to defaults."
     398msgstr ""
     399
     400#: classes/Views/SettingsTabs.php:277
     401msgid "XML-RPC Settings"
     402msgstr ""
     403
     404#: classes/Views/SettingsTabs.php:280
     405msgid "Enable XML-RPC"
     406msgstr ""
     407
     408#: classes/Views/UserProfile.php:54
     409msgid "Secured WP - Options"
     410msgstr ""
     411
     412#: classes/Views/UserProfile.php:55
     413msgid "Current devices with \"Remember Me\" option enabled"
     414msgstr ""
     415
     416#: classes/Views/UserProfile.php:60
     417#: classes/Views/UserProfile.php:122
     418msgid "Device"
     419msgstr ""
     420
     421#: classes/Views/UserProfile.php:63
     422#: classes/Views/UserProfile.php:125
     423msgid "Expires"
     424msgstr ""
     425
     426#: classes/Views/UserProfile.php:66
     427#: classes/Views/UserProfile.php:99
     428#: classes/Views/UserProfile.php:128
     429msgid "Remove"
     430msgstr ""
     431
     432#: classes/Views/UserProfile.php:76
     433msgid "No logged in devices found"
     434msgstr ""
     435
     436#: classes/Views/UserProfile.php:90
     437msgid "Expired"
     438msgstr ""
     439
     440#: classes/Views/UserProfile.php:139
     441msgid "Remove all logged in devices"
     442msgstr ""
     443
     444#: classes/Views/UserProfile.php:174
     445msgid "QR code for the TOTP 2FA login"
     446msgstr ""
     447
     448#: classes/Views/UserProfile.php:187
     449msgid "Or use the following key, by entering it directly in you preferable authentication application:"
     450msgstr ""
     451
     452#: classes/Views/UserProfile.php:200
     453msgid "Regenerate QR code"
     454msgstr ""
     455
     456#: classes/Views/UsersList.php:177
     457msgid "Locked status"
     458msgstr ""
     459
     460#: classes/Views/UsersList.php:210
     461msgid "Locked"
     462msgstr ""
     463
     464#: classes/Views/UsersList.php:210
     465msgid "Not Locked"
     466msgstr ""
     467
     468#: classes/Views/UsersList.php:228
     469msgid "Secured WP Status"
     470msgstr ""
     471
     472#: classes/Views/UsersList.php:265
     473#: classes/Views/UsersList.php:327
     474msgid "Logged in"
     475msgstr ""
     476
     477#: classes/Views/UsersList.php:284
     478msgid "Logged"
     479msgstr ""
     480
     481#: classes/Views/UsersList.php:284
     482msgid "Not Logged"
     483msgstr ""
     484
     485#: classes/Views/UsersList.php:347
     486msgid "Lock Users"
     487msgstr ""
     488
     489#: classes/Views/UsersList.php:348
     490msgid "Unlock Users"
     491msgstr ""
     492
     493#: classes/Views/UsersList.php:350
     494msgid "Exclude from WP 2FA"
     495msgstr ""
     496
     497#: classes/Views/UsersList.php:351
     498msgid "Include in WP 2FA"
     499msgstr ""
     500
     501#. translators: %s: Number of users
     502#: classes/Views/UsersList.php:431
     503msgid "Locked %s user."
     504msgid_plural "Locked %s users."
     505msgstr[0] ""
     506msgstr[1] ""
     507
     508#. translators: %s: Number of users
     509#: classes/Views/UsersList.php:447
     510msgid "Unlocked %s user."
     511msgid_plural "Unlocked %s users."
     512msgstr[0] ""
     513msgstr[1] ""
     514
     515#: classes/Views/UsersList.php:475
     516#: classes/Views/UsersList.php:477
     517msgid "Filter Role"
     518msgstr ""
     519
     520#. translators: %s: Customer username
     521#: templates/template-oob.php:14
     522msgid "Hi %s,"
     523msgstr ""
  • secured-wp/trunk/readme.txt

    r2579464 r2636555  
    55Tested up to: 5.8
    66Requires PHP: 7.2
    7 Stable tag: 1.5
     7Stable tag: 1.6
    88License: GPLv2 or later
    99License URI: http://www.gnu.org/licenses/gpl-2.0.html
     
    1212
    1313== Description ==
    14 Adds layer of security for your WordPress site. Adds custom login page slug, enables 2FA, removes security issues. Adds remember device, counts login attempts and lock usernames if the password is wrong. Out of bond e-mail is also supported - instead of entering codes, your user can use simple login link from within their e-mail client.
     14Adds layer of security for your WordPress site. Adds custom login page slug, enables 2FA, removes security issues. Adds remember device, counts login attempts and lock usernames if the password is wrong. Out of band e-mail is also supported - instead of entering codes, your user can use simple login link from within their e-mail client.
    1515
    1616<strong>Woocommerce</strong>
     
    22221. <strong>Login redirection</strong> - redirects the default wp-login.php to a slug of your choice
    23232. <strong>Login attempts</strong> - counts the unsuccessful attempts, and locks user if there are too many
    24 3. <strong>2FA settings</strong> - gives the ability to use two factor authentication and Out Of Bond email link
     243. <strong>2FA settings</strong> - gives the ability to use two factor authentication and Out Of Band email link
    25254. <strong>Remember devices</strong> - current device could be remembered for given amount of days and user wont be asked to login again before that
    26265. <strong>Removes XML-RPC</strong> from your WordPress site
     
    68681. Main screen of the plugin, settings tabs and information about the settings
    69692. 2FA login screen, user does not have enabled 2FA yet
    70 3. E-mail with the Out of Bond link
     703. E-mail with the Out of Band link
    71714. Woocommerce My Profile page
    72725. Extends default Users menu bulk actions
  • secured-wp/trunk/secured-wp.php

    r2579464 r2636555  
    1616 * Plugin URI:        https://wp-secured.com
    1717 * Description:       Provides Security for WP sites. 2FA, login attempts, hardens WP login process
    18  * Version:           1.5
     18 * Version:           1.7
    1919 * Author:            wp-secured
    2020 * Author URI:        https://wp-secured.com
     
    2222 * License:           GPL-2.0+
    2323 * License URI:       http://www.gnu.org/licenses/gpl-2.0.txt
    24  * Text Domain:       wp-secured
     24 * Text Domain:       secured-wp
    2525 * Domain Path:       /languages
    2626 * License:           GPL2 or later
  • secured-wp/trunk/vendor/composer/autoload_psr4.php

    r2576070 r2636555  
    1313    'ParagonIE\\ConstantTime\\' => array($vendorDir . '/paragonie/constant_time_encoding/src'),
    1414    'OTPHP\\' => array($vendorDir . '/spomky-labs/otphp/src'),
     15    'Endroid\\QrCode\\' => array($vendorDir . '/endroid/qr-code/src'),
     16    'DASPRiD\\Enum\\' => array($vendorDir . '/dasprid/enum/src'),
     17    'BaconQrCode\\' => array($vendorDir . '/bacon/bacon-qr-code/src'),
    1518    'Assert\\' => array($vendorDir . '/beberlei/assert/lib/Assert'),
    1619);
  • secured-wp/trunk/vendor/composer/autoload_static.php

    r2576070 r2636555  
    122122            'OTPHP\\' => 6,
    123123        ),
     124        'E' =>
     125        array (
     126            'Endroid\\QrCode\\' => 15,
     127        ),
     128        'D' =>
     129        array (
     130            'DASPRiD\\Enum\\' => 13,
     131        ),
     132        'B' =>
     133        array (
     134            'BaconQrCode\\' => 12,
     135        ),
    124136        'A' =>
    125137        array (
     
    154166        array (
    155167            0 => __DIR__ . '/..' . '/spomky-labs/otphp/src',
     168        ),
     169        'Endroid\\QrCode\\' =>
     170        array (
     171            0 => __DIR__ . '/..' . '/endroid/qr-code/src',
     172        ),
     173        'DASPRiD\\Enum\\' =>
     174        array (
     175            0 => __DIR__ . '/..' . '/dasprid/enum/src',
     176        ),
     177        'BaconQrCode\\' =>
     178        array (
     179            0 => __DIR__ . '/..' . '/bacon/bacon-qr-code/src',
    156180        ),
    157181        'Assert\\' =>
  • secured-wp/trunk/vendor/composer/installed.json

    r2576070 r2636555  
    11[
     2    {
     3        "name": "bacon/bacon-qr-code",
     4        "version": "2.0.4",
     5        "version_normalized": "2.0.4.0",
     6        "source": {
     7            "type": "git",
     8            "url": "https://github.com/Bacon/BaconQrCode.git",
     9            "reference": "f73543ac4e1def05f1a70bcd1525c8a157a1ad09"
     10        },
     11        "dist": {
     12            "type": "zip",
     13            "url": "https://api.github.com/repos/Bacon/BaconQrCode/zipball/f73543ac4e1def05f1a70bcd1525c8a157a1ad09",
     14            "reference": "f73543ac4e1def05f1a70bcd1525c8a157a1ad09",
     15            "shasum": ""
     16        },
     17        "require": {
     18            "dasprid/enum": "^1.0.3",
     19            "ext-iconv": "*",
     20            "php": "^7.1 || ^8.0"
     21        },
     22        "require-dev": {
     23            "phly/keep-a-changelog": "^1.4",
     24            "phpunit/phpunit": "^7 | ^8 | ^9",
     25            "squizlabs/php_codesniffer": "^3.4"
     26        },
     27        "suggest": {
     28            "ext-imagick": "to generate QR code images"
     29        },
     30        "time": "2021-06-18T13:26:35+00:00",
     31        "type": "library",
     32        "installation-source": "dist",
     33        "autoload": {
     34            "psr-4": {
     35                "BaconQrCode\\": "src/"
     36            }
     37        },
     38        "notification-url": "https://packagist.org/downloads/",
     39        "license": [
     40            "BSD-2-Clause"
     41        ],
     42        "authors": [
     43            {
     44                "name": "Ben Scholzen 'DASPRiD'",
     45                "email": "mail@dasprids.de",
     46                "homepage": "https://dasprids.de/",
     47                "role": "Developer"
     48            }
     49        ],
     50        "description": "BaconQrCode is a QR code generator for PHP.",
     51        "homepage": "https://github.com/Bacon/BaconQrCode"
     52    },
    253    {
    354        "name": "beberlei/assert",
     
    63114            "assertion",
    64115            "validation"
     116        ]
     117    },
     118    {
     119        "name": "dasprid/enum",
     120        "version": "1.0.3",
     121        "version_normalized": "1.0.3.0",
     122        "source": {
     123            "type": "git",
     124            "url": "https://github.com/DASPRiD/Enum.git",
     125            "reference": "5abf82f213618696dda8e3bf6f64dd042d8542b2"
     126        },
     127        "dist": {
     128            "type": "zip",
     129            "url": "https://api.github.com/repos/DASPRiD/Enum/zipball/5abf82f213618696dda8e3bf6f64dd042d8542b2",
     130            "reference": "5abf82f213618696dda8e3bf6f64dd042d8542b2",
     131            "shasum": ""
     132        },
     133        "require-dev": {
     134            "phpunit/phpunit": "^7 | ^8 | ^9",
     135            "squizlabs/php_codesniffer": "^3.4"
     136        },
     137        "time": "2020-10-02T16:03:48+00:00",
     138        "type": "library",
     139        "installation-source": "dist",
     140        "autoload": {
     141            "psr-4": {
     142                "DASPRiD\\Enum\\": "src/"
     143            }
     144        },
     145        "notification-url": "https://packagist.org/downloads/",
     146        "license": [
     147            "BSD-2-Clause"
     148        ],
     149        "authors": [
     150            {
     151                "name": "Ben Scholzen 'DASPRiD'",
     152                "email": "mail@dasprids.de",
     153                "homepage": "https://dasprids.de/",
     154                "role": "Developer"
     155            }
     156        ],
     157        "description": "PHP 7.1 enum implementation",
     158        "keywords": [
     159            "enum",
     160            "map"
     161        ]
     162    },
     163    {
     164        "name": "endroid/qr-code",
     165        "version": "4.3.4",
     166        "version_normalized": "4.3.4.0",
     167        "source": {
     168            "type": "git",
     169            "url": "https://github.com/endroid/qr-code.git",
     170            "reference": "4832304da7c3c0e958c968914185a01ac24cfce4"
     171        },
     172        "dist": {
     173            "type": "zip",
     174            "url": "https://api.github.com/repos/endroid/qr-code/zipball/4832304da7c3c0e958c968914185a01ac24cfce4",
     175            "reference": "4832304da7c3c0e958c968914185a01ac24cfce4",
     176            "shasum": ""
     177        },
     178        "require": {
     179            "bacon/bacon-qr-code": "^2.0",
     180            "php": "^7.3||^8.0"
     181        },
     182        "require-dev": {
     183            "endroid/quality": "dev-master",
     184            "ext-gd": "*",
     185            "khanamiryan/qrcode-detector-decoder": "^1.0.4",
     186            "setasign/fpdf": "^1.8.2"
     187        },
     188        "suggest": {
     189            "ext-gd": "Enables you to write PNG images",
     190            "khanamiryan/qrcode-detector-decoder": "Enables you to use the image validator",
     191            "roave/security-advisories": "Makes sure package versions with known security issues are not installed",
     192            "setasign/fpdf": "Enables you to use the PDF writer"
     193        },
     194        "time": "2021-09-16T18:33:57+00:00",
     195        "type": "library",
     196        "extra": {
     197            "branch-alias": {
     198                "dev-master": "4.x-dev"
     199            }
     200        },
     201        "installation-source": "dist",
     202        "autoload": {
     203            "psr-4": {
     204                "Endroid\\QrCode\\": "src/"
     205            }
     206        },
     207        "notification-url": "https://packagist.org/downloads/",
     208        "license": [
     209            "MIT"
     210        ],
     211        "authors": [
     212            {
     213                "name": "Jeroen van den Enden",
     214                "email": "info@endroid.nl"
     215            }
     216        ],
     217        "description": "Endroid QR Code",
     218        "homepage": "https://github.com/endroid/qr-code",
     219        "keywords": [
     220            "code",
     221            "endroid",
     222            "php",
     223            "qr",
     224            "qrcode"
     225        ],
     226        "funding": [
     227            {
     228                "url": "https://github.com/endroid",
     229                "type": "github"
     230            }
    65231        ]
    66232    },
     
    191357    {
    192358        "name": "scssphp/scssphp",
    193         "version": "v1.6.0",
    194         "version_normalized": "1.6.0.0",
     359        "version": "v1.8.1",
     360        "version_normalized": "1.8.1.0",
    195361        "source": {
    196362            "type": "git",
    197363            "url": "https://github.com/scssphp/scssphp.git",
    198             "reference": "b83594e2323c5d6e80785df3f91b9d1d32aad530"
    199         },
    200         "dist": {
    201             "type": "zip",
    202             "url": "https://api.github.com/repos/scssphp/scssphp/zipball/b83594e2323c5d6e80785df3f91b9d1d32aad530",
    203             "reference": "b83594e2323c5d6e80785df3f91b9d1d32aad530",
     364            "reference": "5e37759a63caf54392a4b709358a39ac7425a69f"
     365        },
     366        "dist": {
     367            "type": "zip",
     368            "url": "https://api.github.com/repos/scssphp/scssphp/zipball/5e37759a63caf54392a4b709358a39ac7425a69f",
     369            "reference": "5e37759a63caf54392a4b709358a39ac7425a69f",
    204370            "shasum": ""
    205371        },
     
    215381            "squizlabs/php_codesniffer": "~3.5",
    216382            "symfony/phpunit-bridge": "^5.1",
     383            "thoughtbot/bourbon": "^7.0",
    217384            "twbs/bootstrap": "~5.0",
    218385            "twbs/bootstrap4": "4.6.0",
     
    223390            "ext-mbstring": "For best performance, mbstring should be installed as it is faster than ext-iconv"
    224391        },
    225         "time": "2021-07-02T16:28:10+00:00",
     392        "time": "2021-09-18T21:20:53+00:00",
    226393        "bin": [
    227394            "bin/pscss"
  • secured-wp/trunk/vendor/scssphp/scssphp/bin/pscss

    r2576070 r2636555  
    2727
    2828$style = null;
    29 $loadPaths = null;
     29$loadPaths = [];
    3030$dumpTree = false;
    3131$inputFile = null;
     
    149149
    150150    if (isset($value)) {
    151         $loadPaths = $value;
     151        $loadPaths[] = $value;
    152152        continue;
    153153    }
     
    189189
    190190if ($loadPaths) {
    191     $scss->setImportPaths(explode(PATH_SEPARATOR, $loadPaths));
     191    $scss->setImportPaths($loadPaths);
    192192}
    193193
  • secured-wp/trunk/vendor/scssphp/scssphp/composer.json

    r2576070 r2636555  
    4141        "squizlabs/php_codesniffer": "~3.5",
    4242        "symfony/phpunit-bridge": "^5.1",
     43        "thoughtbot/bourbon": "^7.0",
    4344        "twbs/bootstrap": "~5.0",
    4445        "twbs/bootstrap4": "4.6.0",
     
    5051            "package": {
    5152                "name": "sass/sass-spec",
    52                 "version": "2021.06.30",
     53                "version": "2021.09.15",
    5354                "source": {
    5455                    "type": "git",
    5556                    "url": "https://github.com/sass/sass-spec.git",
    56                     "reference": "e348959657f1e274cef658283436a311a925a673"
     57                    "reference": "eb2d7a0865c1faf0b55a39ff962b24aca9b4c955"
    5758                },
    5859                "dist": {
    5960                    "type": "zip",
    60                     "url": "https://api.github.com/repos/sass/sass-spec/zipball/e348959657f1e274cef658283436a311a925a673",
    61                     "reference": "e348959657f1e274cef658283436a311a925a673",
     61                    "url": "https://api.github.com/repos/sass/sass-spec/zipball/eb2d7a0865c1faf0b55a39ff962b24aca9b4c955",
     62                    "reference": "eb2d7a0865c1faf0b55a39ff962b24aca9b4c955",
     63                    "shasum": ""
     64                }
     65            }
     66        },
     67        {
     68            "type": "package",
     69            "package": {
     70                "name": "thoughtbot/bourbon",
     71                "version": "v7.0.0",
     72                "source": {
     73                    "type": "git",
     74                    "url": "https://github.com/thoughtbot/bourbon.git",
     75                    "reference": "fbe338ee6807e7f7aa996d82c8a16f248bb149b3"
     76                },
     77                "dist": {
     78                    "type": "zip",
     79                    "url": "https://api.github.com/repos/thoughtbot/bourbon/zipball/fbe338ee6807e7f7aa996d82c8a16f248bb149b3",
     80                    "reference": "fbe338ee6807e7f7aa996d82c8a16f248bb149b3",
    6281                    "shasum": ""
    6382                }
  • secured-wp/trunk/vendor/scssphp/scssphp/src/Compiler.php

    r2576070 r2636555  
    195195
    196196    /**
     197     * @var bool
     198     */
     199    private $charset = true;
     200
     201    /**
    197202     * @var string|\ScssPhp\ScssPhp\Formatter
    198203     */
     
    222227    /**
    223228     * @var bool|null
     229     *
     230     * @deprecated
    224231     */
    225232    protected $charsetSeen;
     
    464471        $this->scope          = null;
    465472        $this->storeEnv       = null;
    466         $this->charsetSeen    = null;
    467473        $this->shouldEvaluate = null;
    468474        $this->ignoreCallStackMessage = false;
     
    517523            $prefix = '';
    518524
    519             if (!$this->charsetSeen) {
    520                 if (strlen($out) !== Util::mbStrlen($out)) {
    521                     $prefix = '@charset "UTF-8";' . "\n";
    522                     $out = $prefix . $out;
    523                 }
     525            if ($this->charset && strlen($out) !== Util::mbStrlen($out)) {
     526                $prefix = '@charset "UTF-8";' . "\n";
     527                $out = $prefix . $out;
    524528            }
    525529
     
    28782882
    28792883            case Type::T_CHARSET:
    2880                 if (! $this->charsetSeen) {
    2881                     $this->charsetSeen = true;
    2882                     $this->appendRootDirective('@charset ' . $this->compileValue($child[1]) . ';', $out);
    2883                 }
    28842884                break;
    28852885
     
    38283828        // try to find a native lib function
    38293829        $normalizedName = $this->normalizeName($name);
    3830         $libName = null;
    38313830
    38323831        if (isset($this->userFunctions[$normalizedName])) {
     
    38373836        }
    38383837
     3838        $lowercasedName = strtolower($normalizedName);
     3839
     3840        // Special functions overriding a CSS function are case-insensitive. We normalize them as lowercase
     3841        // to avoid the deprecation warning about the wrong case being used.
     3842        if ($lowercasedName === 'min' || $lowercasedName === 'max') {
     3843            $normalizedName = $lowercasedName;
     3844        }
     3845
    38393846        if (($f = $this->getBuiltinFunction($normalizedName)) && \is_callable($f)) {
    38403847            $libName   = $f[1];
    38413848            $prototype = isset(static::$$libName) ? static::$$libName : null;
     3849
     3850            // All core functions have a prototype defined. Not finding the
     3851            // prototype can mean 2 things:
     3852            // - the function comes from a child class (deprecated just after)
     3853            // - the function was found with a different case, which relates to calling the
     3854            //   wrong Sass function due to our camelCase usage (`fade-in()` vs `fadein()`),
     3855            //   because PHP method names are case-insensitive while property names are
     3856            //   case-sensitive.
     3857            if ($prototype === null || strtolower($normalizedName) !== $normalizedName) {
     3858                $r = new \ReflectionMethod($this, $libName);
     3859                $actualLibName = $r->name;
     3860
     3861                if ($actualLibName !== $libName || strtolower($normalizedName) !== $normalizedName) {
     3862                    $kebabCaseName = preg_replace('~(?<=\\w)([A-Z])~', '-$1', substr($actualLibName, 3));
     3863                    assert($kebabCaseName !== null);
     3864                    $originalName = strtolower($kebabCaseName);
     3865                    $warning = "Calling built-in functions with a non-standard name is deprecated since Scssphp 1.8.0 and will not work anymore in 2.0 (they will be treated as CSS function calls instead).\nUse \"$originalName\" instead of \"$name\".";
     3866                    @trigger_error($warning, E_USER_DEPRECATED);
     3867                    $fname = $this->getPrettyPath($this->sourceNames[$this->sourceIndex]);
     3868                    $line  = $this->sourceLine;
     3869                    Warn::deprecation("$warning\n         on line $line of $fname");
     3870
     3871                    // Use the actual function definition
     3872                    $prototype = isset(static::$$actualLibName) ? static::$$actualLibName : null;
     3873                    $f[1] = $libName = $actualLibName;
     3874                }
     3875            }
    38423876
    38433877            if (\get_class($this) !== __CLASS__ && !isset($this->warnedChildFunctions[$libName])) {
     
    55005534
    55015535    /**
     5536     * Configures the handling of non-ASCII outputs.
     5537     *
     5538     * If $charset is `true`, this will include a `@charset` declaration or a
     5539     * UTF-8 [byte-order mark][] if the stylesheet contains any non-ASCII
     5540     * characters. Otherwise, it will never include a `@charset` declaration or a
     5541     * byte-order mark.
     5542     *
     5543     * [byte-order mark]: https://en.wikipedia.org/wiki/Byte_order_mark#UTF-8
     5544     *
     5545     * @param bool $charset
     5546     *
     5547     * @return void
     5548     */
     5549    public function setCharset($charset)
     5550    {
     5551        $this->charset = $charset;
     5552    }
     5553
     5554    /**
    55025555     * Enable/disable source maps
    55035556     *
     
    58735926
    58745927        if (0 === strpos($normalizedPath, $normalizedRootDirectory)) {
    5875             return substr($normalizedPath, \strlen($normalizedRootDirectory));
     5928            return substr($path, \strlen($normalizedRootDirectory));
    58765929        }
    58775930
     
    72107263     *
    72117264     * @return integer|float
     7265     *
     7266     * @deprecated
    72127267     */
    72137268    protected function coercePercent($value)
    72147269    {
     7270        @trigger_error(sprintf('"%s" is deprecated since 1.7.0.', __METHOD__), E_USER_DEPRECATED);
     7271
    72157272        if ($value instanceof Number) {
    72167273            if ($value->hasUnit('%')) {
     
    74397496        }
    74407497
    7441         return [Type::T_HSL, fmod($h, 360), $s * 100, $l / 5.1];
     7498        return [Type::T_HSL, fmod($h + 360, 360), $s * 100, $l / 5.1];
    74427499    }
    74437500
     
    77207777                    }
    77217778                } else {
    7722                     $color = [Type::T_STRING, '', [$funcName . '(', $args[0], ')']];
     7779                    $color = [Type::T_STRING, '', [$funcName . '(', $args[0], ', ', $args[1], ')']];
    77237780                }
    77247781                break;
     
    80218078    // mix two colors
    80228079    protected static $libMix = [
    8023         ['color1', 'color2', 'weight:0.5'],
    8024         ['color-1', 'color-2', 'weight:0.5']
     8080        ['color1', 'color2', 'weight:50%'],
     8081        ['color-1', 'color-2', 'weight:50%']
    80258082        ];
    80268083    protected function libMix($args)
     
    80308087        $first = $this->assertColor($first, 'color1');
    80318088        $second = $this->assertColor($second, 'color2');
    8032         $weight = $this->coercePercent($this->assertNumber($weight, 'weight'));
     8089        $weightScale = $this->assertNumber($weight, 'weight')->valueInRange(0, 100, 'weight') / 100;
    80338090
    80348091        $firstAlpha = isset($first[4]) ? $first[4] : 1;
    80358092        $secondAlpha = isset($second[4]) ? $second[4] : 1;
    80368093
    8037         $w = $weight * 2 - 1;
    8038         $a = $firstAlpha - $secondAlpha;
    8039 
    8040         $w1 = (($w * $a === -1 ? $w : ($w + $a) / (1 + $w * $a)) + 1) / 2.0;
    8041         $w2 = 1.0 - $w1;
     8094        $normalizedWeight = $weightScale * 2 - 1;
     8095        $alphaDistance = $firstAlpha - $secondAlpha;
     8096
     8097        $combinedWeight = $normalizedWeight * $alphaDistance == -1 ? $normalizedWeight : ($normalizedWeight + $alphaDistance) / (1 + $normalizedWeight * $alphaDistance);
     8098        $weight1 = ($combinedWeight + 1) / 2.0;
     8099        $weight2 = 1.0 - $weight1;
    80428100
    80438101        $new = [Type::T_COLOR,
    8044             $w1 * $first[1] + $w2 * $second[1],
    8045             $w1 * $first[2] + $w2 * $second[2],
    8046             $w1 * $first[3] + $w2 * $second[3],
     8102            $weight1 * $first[1] + $weight2 * $second[1],
     8103            $weight1 * $first[2] + $weight2 * $second[2],
     8104            $weight1 * $first[3] + $weight2 * $second[3],
    80478105        ];
    80488106
    80498107        if ($firstAlpha != 1.0 || $secondAlpha != 1.0) {
    8050             $new[] = $firstAlpha * $weight + $secondAlpha * (1 - $weight);
     8108            $new[] = $firstAlpha * $weightScale + $secondAlpha * (1 - $weightScale);
    80518109        }
    80528110
     
    81258183        }
    81268184
    8127         $hueValue = $hue->getDimension() % 360;
     8185        $hueValue = fmod($hue->getDimension(), 360);
    81288186
    81298187        while ($hueValue < 0) {
     
    83078365        $hsl = $this->toHSL($color[1], $color[2], $color[3]);
    83088366        $hsl[$idx] += $amount;
     8367
     8368        if ($idx !== 1) {
     8369            // Clamp the saturation and lightness
     8370            $hsl[$idx] = min(max(0, $hsl[$idx]), 100);
     8371        }
     8372
    83098373        $out = $this->toRGB($hsl[1], $hsl[2], $hsl[3]);
    83108374
     
    83548418        }
    83558419
    8356         $color = $this->assertColor($value, 'color');
    8357         $amount = 100 * $this->coercePercent($this->assertNumber($args[1], 'amount'));
    8358 
    8359         return $this->adjustHsl($color, 2, $amount);
     8420        $color = $this->assertColor($args[0], 'color');
     8421        $amount = $this->assertNumber($args[1], 'amount');
     8422
     8423        return $this->adjustHsl($color, 2, $amount->valueInRange(0, 100, 'amount'));
    83608424    }
    83618425
     
    83648428    {
    83658429        $color = $this->assertColor($args[0], 'color');
    8366         $amount = 100 * $this->coercePercent($this->assertNumber($args[1], 'amount'));
    8367 
    8368         return $this->adjustHsl($color, 2, -$amount);
     8430        $amount = $this->assertNumber($args[1], 'amount');
     8431
     8432        return $this->adjustHsl($color, 2, -$amount->valueInRange(0, 100, 'amount'));
    83698433    }
    83708434
     
    83878451    }
    83888452
    8389     protected static $libInvert = ['color', 'weight:1'];
     8453    protected static $libInvert = ['color', 'weight:100%'];
    83908454    protected function libInvert($args)
    83918455    {
    83928456        $value = $args[0];
    83938457
     8458        $weight = $this->assertNumber($args[1], 'weight');
     8459
    83948460        if ($value instanceof Number) {
     8461            if ($weight->getDimension() != 100 || !$weight->hasUnit('%')) {
     8462                throw new SassScriptException('Only one argument may be passed to the plain-CSS invert() function.');
     8463            }
     8464
    83958465            return null;
    83968466        }
    8397 
    8398         $weight = $this->coercePercent($this->assertNumber($args[1], 'weight'));
    83998467
    84008468        $color = $this->assertColor($value, 'color');
     
    84048472        $inverted[3] = 255 - $inverted[3];
    84058473
    8406         if ($weight < 1) {
    8407             return $this->libMix([$inverted, $color, new Number($weight, '')]);
    8408         }
    8409 
    8410         return $inverted;
     8474        return $this->libMix([$inverted, $color, $weight]);
    84118475    }
    84128476
     
    84168480    {
    84178481        $color = $this->assertColor($args[0], 'color');
    8418         $amount = $this->coercePercent($this->assertNumber($args[1], 'amount'));
    8419 
    8420         $color[4] = (isset($color[4]) ? $color[4] : 1) + $amount;
     8482        $amount = $this->assertNumber($args[1], 'amount');
     8483
     8484        $color[4] = (isset($color[4]) ? $color[4] : 1) + $amount->valueInRange(0, 1, 'amount');
    84218485        $color[4] = min(1, max(0, $color[4]));
    84228486
     
    84358499    {
    84368500        $color = $this->assertColor($args[0], 'color');
    8437         $amount = $this->coercePercent($this->assertNumber($args[1], 'amount'));
    8438 
    8439         $color[4] = (isset($color[4]) ? $color[4] : 1) - $amount;
     8501        $amount = $this->assertNumber($args[1], 'amount');
     8502
     8503        $color[4] = (isset($color[4]) ? $color[4] : 1) - $amount->valueInRange(0, 1, 'amount');
    84408504        $color[4] = min(1, max(0, $color[4]));
    84418505
  • secured-wp/trunk/vendor/scssphp/scssphp/src/Node/Number.php

    r2576070 r2636555  
    150150     * {@inheritdoc}
    151151     */
     152    #[\ReturnTypeWillChange]
    152153    public function offsetExists($offset)
    153154    {
     
    175176     * {@inheritdoc}
    176177     */
     178    #[\ReturnTypeWillChange]
    177179    public function offsetGet($offset)
    178180    {
     
    201203     * {@inheritdoc}
    202204     */
     205    #[\ReturnTypeWillChange]
    203206    public function offsetSet($offset, $value)
    204207    {
     
    209212     * {@inheritdoc}
    210213     */
     214    #[\ReturnTypeWillChange]
    211215    public function offsetUnset($offset)
    212216    {
  • secured-wp/trunk/vendor/scssphp/scssphp/src/Parser.php

    r2576070 r2636555  
    15811581                        list($line, $column) = $this->getSourcePosition($this->count);
    15821582                        $file = $this->sourceName;
    1583                         $this->logger->warn("Unterminated interpolations in multiline comments are deprecated and will be removed in ScssPhp 2.0, in \"$file\", line $line, column $column.", true);
     1583                        if (!$this->discardComments) {
     1584                            $this->logger->warn("Unterminated interpolations in multiline comments are deprecated and will be removed in ScssPhp 2.0, in \"$file\", line $line, column $column.", true);
     1585                        }
    15841586                        $comment[] = substr($this->buffer, $this->count, 2);
    15851587
  • secured-wp/trunk/vendor/scssphp/scssphp/src/Version.php

    r2576070 r2636555  
    2020class Version
    2121{
    22     const VERSION = '1.6.0';
     22    const VERSION = '1.8.1';
    2323}
Note: See TracChangeset for help on using the changeset viewer.