The SMTP password disappears everytime I save the settings,

The SMTP password disappears everytime I save the settings, so it won't allow me to send any newsletters.

  • Sajid

    Hi @JD Duncan

    Hope you are doing good today :slight_smile:

    There seems be encryption issue with password length, we have been reported this issue in the past and one of our developer fixed this issue by doing following changes.

    Go to file /e-newsletter/email-newsletter-files/class.functions.php via FTP or FileManager open it, find below code.

    protected function _encrypt( $text ) {
            if  ( function_exists( 'mcrypt_encrypt' ) ) {
                return base64_encode( @mcrypt_encrypt( MCRYPT_RIJNDAEL_256, DB_PASSWORD, $text, MCRYPT_MODE_ECB ) );
            } else {
                return $text;
            }
        }
    
        /**
         * Decrypt password (SMTP & POP password)
         **/
        protected function _decrypt( $text ) {
            if ( function_exists( 'mcrypt_decrypt' ) ) {
                return trim( @mcrypt_decrypt( MCRYPT_RIJNDAEL_256, DB_PASSWORD, base64_decode( $text ), MCRYPT_MODE_ECB ) );
            } else {
                return $text;
            }
        }

    And replace it with this one.

    protected function _encrypt( $text ) {
            if  ( function_exists( 'mcrypt_encrypt' ) ) {
                return base64_encode( @mcrypt_encrypt( MCRYPT_RIJNDAEL_256, md5(DB_PASSWORD), $text, MCRYPT_MODE_ECB ) );
            } else {
                return $text;
            }
        }
    
        /**
         * Decrypt password (SMTP & POP password)
         **/
        protected function _decrypt( $text ) {
            if ( function_exists( 'mcrypt_decrypt' ) ) {
                return trim( @mcrypt_decrypt( MCRYPT_RIJNDAEL_256, md5(DB_PASSWORD), base64_decode( $text ), MCRYPT_MODE_ECB ) );
            } else {
                return $text;
            }
        }

    Save changes and upload back to server. If you are not sure how to make that change then send me FTP details along WordPress admin login details (for testing) and I will do that for you. Include following information in your message.

    Subject: "Attn: Sajid Javed"
    -WordPress admin username
    -WordPress admin password
    -login url
    -FTP credentials (host/username/password)
    -link back to this thread for reference
    -any other relevant urls

    Select "I have a different question" for your topic - this and the subject line ensure that it gets assigned to me :slight_smile:

    https://premium.wpmudev.org/contact/

    Hope that helps :slight_smile:

    Cheers, Sajid

Thank NAME, for their help.

Let NAME know exactly why they deserved these points.

Gift a custom amount of points.