Show Posts

This section allows you to view all posts made by this member. Note that you can only see posts made in areas you currently have access to.

Messages - infinitech07

Pages: 1 [2] 3
Informations / Re: How to Secure CWP webserver
« on: April 20, 2016, 06:26:35 AM »
I did play around with the letsencrypt SSL few days ago, taking me quite some times to get it installed.

First, you must make sure you have at least the Python v2.7.x or above, and also the virtualenv installed.

Install the letsencrypt.
cd /root
git clone
cd letsencrypt

And if you get the following error, please refer to the link,, to get the virtualenv installed.
virtualenv: command not found

In fact, I still got the error (not virtualenv error, could not remember thou) when running ./letsencrypt-auto command. So, I did in manual method to generate the SSL.
./letsencrypt-auto certonly --webroot -w /home/your_domain/public_html -d -d

Then,  copy the SSL into /etc/pki/tls directory.
cp -f /etc/letsencrypt/live/your_domain/cert.pem /etc/pki/tls/certs/your_domain.cert
cp -f /etc/letsencrypt/live/your_domain/fullchain.pem /etc/pki/tls/certs/your_domain.bundle
cp -f /etc/letsencrypt/live/your_domain/privkey.pem /etc/pki/tls/certs/your_domain.key

At your CWP, go to Apache settings >> SSL cert manager, on your right hand side form, choose the cert, user & enter your domain; then install SSL. Done.

Note: Make sure you have the 443 port open in firewall & listen to port 443.

You may test the score of SSL cert at
At the beginning, I got the score C and after did some researches, I added the following lines onto this file /usr/local/apache/conf.d/vhosts-ssl.conf.
SSLEngine on
SSLProtocol All -SSLv2 -SSLv3
SSLCompression Off
SSLHonorCipherOrder On
Restart the apache.

I got the score A now.  ;D Hope this guide will help you. Cheer.

CSF Firewall / Re: Suspicious File Alert?
« on: April 19, 2016, 07:27:22 AM »

MySQL / Re: MySQL error (MySQL server has gone away) on restart
« on: January 29, 2016, 08:04:56 AM »
This happened to my servers as well. Some of my client's websites stop working because of the database did not return any data from server. Before this, all these are working just fine.

Anyone got clue about this issue?

MySQL / Re: Error message when restarting mysql
« on: January 29, 2016, 08:01:01 AM »
I had the same problem occurred. CWP version: Restart mysqld from command line no error shown. Any idea?

Warning: Error while sending SET_OPTION packet. PID=31857 in /usr/local/cwpsrv/htdocs/resources/admin/include/functions.php(1) : eval()'d code(1) : eval()'d code on line 5
MySQL server has gone away
Warning: mysql_fetch_array() expects parameter 1 to be resource, boolean given in /usr/local/cwpsrv/htdocs/resources/admin/include/functions.php(1) : eval()'d code(1) : eval()'d code on line 5

E-Mail / Re: Change E-Mail Password
« on: January 07, 2016, 01:32:42 PM »
Hello, Did it work for anyone? I tried the settings as described, including this one "$config['password_query'] = 'UPDATE mailbox SET password=%c,modified=NOW() WHERE username=%u LIMIT 1';"
But I still get the error cannot save new password. I also tried with the default value for this config. $rcmail_config['password_query'] = 'SELECT update_passwd(%c, %u)';
Still did not work for me.
Is there anything that I am missing, do you think? Would really love to have this option.


I just done it on another server for my client and it still worked for me.  ;D

The password query should work if you never set or change the default webmail database. Make sure you have the right settings on those config files OR you may check the error stated on log file.

Hope this help.

PHP / Re: Lib JPEG Support php-gd
« on: October 22, 2015, 07:10:01 AM »
I have the same problem after upgraded to php 5.5.11.

Now it is being resolved. Thanks for the solution provided.  :)

PHP / Re: PHP Version Switcher
« on: October 22, 2015, 07:07:32 AM »
Is okay. I had updated to the version 5.5.11 anyway. Thanks.

PHP / Re: PHP Version Switcher
« on: October 18, 2015, 02:42:21 PM »
I guess the latest CWP version still having the same issue where I did the php recompilation from 5.4 to 5.3 and from 5.3 back to 5.4 again. On php -v it showed 5.4 but the php info page still showing 5.3.

Postfix / Re: Freshclam DB update fail
« on: October 18, 2015, 01:39:36 PM »
The weird thing that I noticed on the old CWP version & the new CWP version is that the user & usergroup of the folders i.e. /var/log/clamav & /var/lib/clamav are different; the old one using "clamav" while the new one using "clam". Why??

Please refer to this post as well regarding the same issue reported lately.

CentOS 6 Problems / Re: CLAMAV update problem
« on: October 18, 2015, 04:52:25 AM »
I have the same problem since after rebuilt the postfix.

Found the solution by myself.

Make sure the /var/lib/clamav & /var/log/clamav with the right user & group.
chown -R clam:clam /var/lib/clamav
chown -R clam:clam /var/log/clamav

Open the file /etc/freshclam.conf and make sure the lines are set to as below:
DatabaseDirectory /var/lib/clamav
DatabaseOwner clam

Also make sure the lines at file /etc/clamd.conf been set to:
DatabaseDirectory /var/lib/clamav
User clam

Then, restart the clamd service and update the database.
service clamd restart

It should works, at least for me yes.  ;)

E-Mail / Re: Change E-Mail Password
« on: October 11, 2015, 03:38:15 PM »
That is also what I'd like to know:
I changed the following:
- in $rcmail_config['plugins'] = array('password');
- I changed in and enabled the following lines:

$rcmail_config['password_db_dsn'] = 'mysql://mypassword@localhost/roundcube';
taken from $rcmail_config['db_dsn'] = 'mysqli://roundcube:mypassword@localhost/roundcube';

$rcmail_config['password_query'] = "UPDATE mailbox SET password=CONCAT('{PLAIN-MD5}', MD5(%p)),modified=NOW() WHERE username=%u LIMIT 1";

I restarted httpd but I get the password line in Roundcube, the 3 lines with current password, new password and repeat new password but when I want to change the password it says password can't be saved, What Am I doing wrong here? please any help?

These are steps I did for the change password plugin on roundcube:
1. Edit the line on /usr/local/apache/htdocs/roundcube/config/ into
$config['plugins'] = array('password');

2. Open up the file /usr/local/cwpsrv/htdocs/resources/admin/include/postfix.php and note down the password.

3. Next, open up the file /usr/local/apache/htdocs/roundcube/plugins/password/ and set the following
$config['password_driver'] = 'sql';
$config['password_db_dsn'] = 'mysql://postfix:password@localhost/postfix';

** Replace the password with the password you have noted down earlier.
$config['password_query'] = "UPDATE mailbox SET password=CONCAT('{PLAIN-MD5}', MD5(%p)),modified=NOW() WHERE username=%u LIMIT 1";

That's it. It worked for me. Cheers.  ;)

CentOS 6 Problems / Re: Centos web panel ip changed but cwp not work
« on: October 07, 2015, 06:36:32 AM »
I also changed the IP of my VPS lately, and few things you need to look into:


And, you might also need to regenerate the self-signed SSL, rebuild the vhost, and rebuild your web server & mail services. Hope this help.

Had sent a ticket to support but no any solution being advised  :-[ very bad support.

hmm...strange it would be the best to check on that with support.

Noted. Will check with support. Thanks.

Hi, did you find solution?

I Have the same problem. i need a solution fast by tomorrow. monday have to be online.


No solution yet. I had re-built the apache server and also the mail server but still no luck. However, the strange thing was the email was able to be forwarded over to another email account without problem.

For now, I set the email forwarding just for receiving the email and sending out email will use back the original email account to send.

Pages: 1 [2] 3