Author Topic: WHMCS Module has an error  (Read 5265 times)

0 Members and 1 Guest are viewing this topic.

Offline
**
WHMCS Module has an error
« on: May 12, 2019, 11:30:00 AM »
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

Quote
function 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...

Quote
function 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)
« Last Edit: May 12, 2019, 11:33:17 AM by adamjedgar »

Offline
***
Re: WHMCS Module has an error
« Reply #1 on: May 14, 2019, 12:40:16 AM »
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/

Offline
**
Re: WHMCS Module has an error
« Reply #2 on: May 14, 2019, 07:41:22 AM »
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?

Offline
*****
Re: WHMCS Module has an error
« Reply #3 on: May 14, 2019, 11:01:14 AM »
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