New in CWP Edge-LatestFree with every CWPpro licenceWebsites up to 300x faster

CWP now includes LSPHP, LSAPI-Cache and CWP Cage at no extra cost with all CWPpro licences. The LSAPI-Cache plugin is integrated into our WordPress and other script installers, and CWP Cage gives every user complete isolation. Available now in the CWP Edge-Latest version.

Get CWPpro ›

WHMCS Module has an error

Started by adamjedgar, May 12, 2019, 11:30:00 AM

Previous topic - Next topic

adamjedgar

Hi guys,
I realise this probably isnt directly a CWP interface bug, however, i dont know where else to put it so that someone fixes the issue.

In the WMCS module the following code contains an error...

Two problems

Problem 1. The WHMCS module php code AdminLink URL is incorrect and returns a 404 error for the admin page

Quotefunction cwp7_AdminLink($params) {
    $code = '<form action="https://'.$params["serverhostname"].':2031/login.php" method="post" target="_blank">
        <input type="hidden" name="user" value="'.$params["serverusername"].'" />
        <input type="hidden" name="password" value="'.$params["serverpassword"].'" />
        <input type="submit" value="Login to Control Panel" />
        </form>';

running this from inside WHMCS produces a 404 error because the URL /login.php doesnt exist. Below is an image of the area in WHMCS where this action is performed and the inspect element alongside...https://drive.google.com/open?id=1JBXZcQjyxgEEpr_uQHad3jZsKX6uagDF



When i manually go to the login page of CWP, the URL is https://..../login/index.php

So, unless there is a better fix for this, the solution for now is to use the following corrected code...

Quotefunction cwp7_AdminLink($params) {
   $code = '<form action="https://'.$params["serverhostname"].':2031/login/index.php" method="post" target="_blank">
        <input type="hidden" name="user" value="'.$params["serverusername"].'" />
        <input type="hidden" name="password" value="'.$params["serverpassword"].'" />
        <input type="submit" value="Login to Control Panel" />
        </form>';
Which takes the admin user to the CWP login screen.

Problem 2

The module copies root user name and password into the web browser which is visible in the inspect element in google chrome (personally i think that is a bad idea there is no reason for this to be passed across to the browser from WHMCS). However, with the incorrect URL issue above, this is not working anyway...so it should be removed from the php code in the module! (which i have not done yet, but i will on my version)

Jamshed Datori

Both are serious issues which needs immediate action by the CWP team.

Please submit the bug details to CWP team via contact form and I hope that they will fix it ASAP.

https://support.centos-webpanel.com/

adamjedgar

That is what this forum is for yes? It is titled "Centos Web Panel Bugs"

There isnt a bug forum for anything else, so this is the best option we have available at this time.

I am not interested in posting a private message via the contact form...no one else has any idea that someone else has a similar problem if such things are not posted publicly.

I have gone into the WHMCS CWP module and altered the php code myself in order to correct part of the problem at my end...so realistically, i wont have to do anything else until a module update is released (hopefully at that time the issue will have been corrected anyway).

What is dissapointing about this issue, there is absolutely no way that whoever wrote the module could not have known about this...one of the very things one does from within whmcs after installing the module and adding a server, is clicking on the "control panel" link to see if the module works!

Another example of very poor development strategy...ie "the right hand doesnt know what the left hand is doing" (this has been a regular complaint about CWP from the get go...no continuity in development! Little bugs that pre release testing should have found are not found, so called "fixes" dont work....

Anyway, the client interface is pretty at least even if what is beneath is as dumb as nuts! Isnt this where "Blonde jokes" came from?

josemnunez

Thanks for your report, we have updated the module online and it is now available for download.

You can also make any type of bug report via this bugs.control-webpanel.com