Password change in Roundcube does not work

Discussion in 'Installation/Configuration' started by muekno, Mar 13, 2022.

  1. Jesse Norell

    Jesse Norell Well-Known Member Staff Member Howtoforge Staff

    From your roundcube host run
    Code:
    openssl s_client -connect 10.10.1.10:8080 -servername admin.domain.de -showcerts
    to see if that host can connect and that 'admin.domain.de' is a name in the certificate presented.
     
  2. muekno

    muekno Active Member HowtoForge Supporter

  3. muekno

    muekno Active Member HowtoForge Supporter

    Is the any possibilty, i.e. a script to check why the soap connection fails.
    Hostname or certificate seams not to be the problem
    Regards
    Rainer
     
  4. Taleman

    Taleman Well-Known Member HowtoForge Supporter

    Have you followed the "Troubleshooting FAQ" of the plugin author?
     
  5. muekno

    muekno Active Member HowtoForge Supporter

    Sorry, but if you read my posts, then you should know it. Only the first issue "can not connect" to host is valid. So as I understand if I set "valid_cert" to false it should work.
    The credentials are double checked, the path, etc. too, The test from Jesse returns correct hostname and and valid certs.
    Regards
    Rainer
    P.S. I followed this FAQ https://github.com/w2c/ispconfig3_roundcube/wiki/Troubleshooting---FAQ
     
  6. Jesse Norell

    Jesse Norell Well-Known Member Staff Member Howtoforge Staff

    You could use the remote API examples as a basis to either troubleshoot the connection or prove that it works and the issue is in the roundcube setup.
     
  7. muekno

    muekno Active Member HowtoForge Supporter

    @jesse where can I find these examples. I know bit programming in PHP, so I think I will mange this.
    Thanks
    Regards
    Rainer
     
  8. till

    till Super Moderator Staff Member ISPConfig Developer

  9. muekno

    muekno Active Member HowtoForge Supporter

    Found this https://www.howtoforge.com/how-to-create-remote-api-scripts-for-ispconfig-3
    Created the following simple script
    Code:
    <?PHP
    $username = 'roundcube';
    $password = 'roundcubepass';
    
    $soap_location = 'http://localhost:8080/ispconfig3/interface/web/remote/index.php';
    $soap_uri = 'http://localhost:8080/ispconfig3/interface/web/remote/';
    
    //$soap_location = 'http://localhost:8080/remote/index.php';
    //$soap_uri = 'http://localhost≈:8080/remote/';
    
    $client = new SoapClient(null, array('location' => $soap_location, 'uri'      => $soap_uri));
    try {
        //* Login to the remote server
        if($session_id = $client->login($username,$password)) {
            echo 'Logged into remote server sucessfully. The SessionID is '.$session_id.'';
    
         //* Logout
         if($client->logout($session_id)) {
            echo "FTP Created";
            }
         }
    }
        catch (SoapFault $e) {
              die('SOAP Error: '.$e->getMessage());
              echo "Please contact the server administator";
    }
    
    ?>;
    
    Testet it with both versions of $soap_location and §soap_uri (long and short version) first on a remote server with fullname instead of localhost and then on the admin server itself with localhost. But i get a "SOAP Error: Bad Request" all the time.
    Can you help me with the script or a hint whats wrong.
    Regards Rainer
     
  10. till

    till Super Moderator Staff Member ISPConfig Developer

    Most likely your ISPConfig UI uses https, but you are using an http URL. Besides that, take a look at the error.log of the web server to find out why you get that 500 error.
     
  11. muekno

    muekno Active Member HowtoForge Supporter

    changed to https, now I get a "SOAP Error: Could not connect to host" even on the admin server itself.
    Rainer
     
  12. till

    till Super Moderator Staff Member ISPConfig Developer

    Do you use a self-signed SSL cert for ISPConfig? If yes, then you must disable SSL cert verification in your soap connect call.
     
  13. muekno

    muekno Active Member HowtoForge Supporter

    No I have a valid LE Certificate, but SSL cert verification is set to false too
    Regards Rainer
     
  14. muekno

    muekno Active Member HowtoForge Supporter

    Connections works
    I put the test script on the mail server. And I get "Logged into remote server sucessfully. The SessionID is na6b1762c3c2f01ca852052300a0836406a7816f4FTP Created;"
    Now we can go to the real Problem, why does the roundcube snapins not works, still get a could not connect to host. The test scrip can connect the roudcube snapin not. Everything on the same remote server
    Found a difference in the test script there ist a soap_uri and a soap_location in the /usr/share/roundcube/plugins/ispconfig3_account/config/config.inc.php there is only a soap_url

    Regards Rainer
     
    Last edited: Mar 22, 2022
  15. till

    till Super Moderator Staff Member ISPConfig Developer

    Both variables are nearly the same, so you can derive one of the variables from the other one. And the RoundCube plugin was working in the past and I'm sure many are using it successfully at the moment, so it's unlikely that there is a general programming error in it's code.
     
  16. muekno

    muekno Active Member HowtoForge Supporter

    I confirm it´s unlikely.
    But Google search brings a lot of older hits about password change problems after upgrades. I am shure that it worked after the plugings came out long ago, and after some upgrade it stops working. See my post about 1,5 year or more ago. As it was not so urgend I did not follow that. But anything must be wrong.
    Is it possible to remove the plugings complete and then do a new fresh reinstall.
    Regards
    Rainer
     
  17. muekno

    muekno Active Member HowtoForge Supporter

    So I went through the code and I found ispconfig3_pass.php in
    /usr/share/roundcube/plugins/ispconfig3_pass/ what seams the script that will be used. In that code rhe config.in.php will be loaded from a subdir config/ but there is only a config.inc.php.dist
    While the parameters are under /usr/share/roundcube/plugins/ispconfig3_account/config/config.inc.php
    I copied config.inc.php to the other config directory, but the same effect could "not connect to host."
    what the mess is wrong, I think something with the directory structure.
    I really like to remove all that plugin code and install it totally new.
    As my test script proves the connection itself works, username and password as soap URL are correct.
    Regards Rainer

    P.S. found roudcube plugins under /var/lib/roundcube/plugins/ what is used?
     
    Last edited: Mar 22, 2022
  18. muekno

    muekno Active Member HowtoForge Supporter

    Finally fixed !!
    added a config.inc.php under /var/lib/roundcube/plugins/ispconfig3_pass/config and it works.
    So something in the install plugin tutorial seams to be not correct
    Regards
    Rainer
     
  19. nhybgtvfr

    nhybgtvfr Well-Known Member HowtoForge Supporter

    ispconfig3_ account, autoreply, autoselect, fetchmail, filter, forward, pass, spam, wblist.

    shouldn't need one there, changing passwords works fine for me, only have config.inc.php.dist in there, api connection details are set in /var/lib/roundcube/plugins/ispconfig3_account/config/config.inc.php

    is the ispconfig3_account plugin enabled in the plugins list in /etc/roundcube/config.inc.php?
     
  20. muekno

    muekno Active Member HowtoForge Supporter

    If you enter the need values in config.inc.php.dist that will work, as it is loaded by default. But I followed the tutorial where a separate config.inc.php is requested. Normaly I follow the tutorial instead of going deep in the code and system to look what I have to do. The plugins are enabled.
     

Share This Page