SSL do not work properly

You need to edit the virtual_host2.conf template in custom directory in custombuild folder...

Otherwise, as sayd, is a permission/owner error.

Regards
 
Is the link from private_html to public_html owned by root, or is it owned by the user? I think it perhaps should be owned by the user.

Jeff
 
this is /usr/local/directadmin/data/templates/custom/virtual_host2.conf. what is wrong? (there is not any virtual_host2.conf file in my directadmin custombuild folder and sub folders.)

Code:
|?DOCROOT=`HOME`/domains/`DOMAIN`/public_html|
|?OPEN_BASEDIR_PATH=`HOME`/:/tmp:/var/tmp:/usr/local/lib/php/|
<VirtualHost |IP|:|PORT_80| |MULTI_IP|>
|CUSTOM|
|?CGI=ScriptAlias /cgi-bin/ `DOCROOT`/cgi-bin/|
	ServerName www.|DOMAIN|
	ServerAlias www.|DOMAIN| |DOMAIN| |SERVER_ALIASES|
	ServerAdmin |ADMIN|
	DocumentRoot |DOCROOT|
	|CGI|

	|USECANONICALNAME|

	#SuexecUserGroup |USER| |GROUP|
RMode config
RUidGid |USER| |GROUP|
RGroups apache 
	CustomLog /var/log/httpd/domains/|DOMAIN|.bytes bytes
	CustomLog /var/log/httpd/domains/|DOMAIN|.log combined
	ErrorLog /var/log/httpd/domains/|DOMAIN|.error.log

	|*if SUSPENDED_REASON|
	<IfModule mod_env.c>
		SetEnv reason |SUSPENDED_REASON|
	</IfModule>
	|*endif|

	<Directory |DOCROOT|>
		Options +Includes -Indexes
|*if CLI="1"|
		php_admin_flag engine |PHP|
		<IfModule !mod_php6.c>
			php_admin_flag safe_mode |SAFE_MODE|
		</IfModule>
		php_admin_value sendmail_path '/usr/sbin/sendmail -t -i -f |USER|@|DOMAIN|'
|*endif|
|*if OPEN_BASEDIR="ON"|
		php_admin_value open_basedir |OPEN_BASEDIR_PATH|
|*endif|
|*if SUPHP="1"|
                suPHP_Engine |PHP|
		suPHP_UserGroup |USER| |GROUP|
|*endif|
	</Directory>
|HANDLERS|
|MIMETYPES|

</VirtualHost>
 
Well if you wanna totaly remove mod_ruid2 you must delete those 3 line from that file:

RMode config
RUidGid |USER| |GROUP|
RGroups apache

If you wanna fix, again, check owner and permission.

Regards
 
this is /usr/local/directadmin/data/templates/custom/virtual_host2_sub.conf

Code:
|?DOCROOT=`HOME`/domains/`DOMAIN`/public_html|
|?OPEN_BASEDIR_PATH=`HOME`/:/tmp:/var/tmp:/usr/local/lib/php/|
<VirtualHost |IP|:|PORT_80| |MULTI_IP|>
|CUSTOM|
|?CGI=ScriptAlias /cgi-bin/ `DOCROOT`/`SUB`/cgi-bin/|
	ServerName www.|SUB|.|DOMAIN|
	ServerAlias www.|SUB|.|DOMAIN| |SUB|.|DOMAIN| |SERVER_ALIASES|
	ServerAdmin |ADMIN|
	DocumentRoot |DOCROOT|/|SUB|
	|CGI|
	
	|USECANONICALNAME|

	SuexecUserGroup |USER| |GROUP|
	CustomLog /var/log/httpd/domains/|DOMAIN|.|SUB|.bytes bytes
	CustomLog /var/log/httpd/domains/|DOMAIN|.|SUB|.log combined
	ErrorLog /var/log/httpd/domains/|DOMAIN|.|SUB|.error.log

	|*if SUSPENDED_REASON|
	<IfModule mod_env.c>
		SetEnv reason |SUSPENDED_REASON|
	</IfModule>
	|*endif|

	<Directory |DOCROOT|/|SUB|>
		Options +Includes -Indexes
|*if CLI="1"|
		php_admin_flag engine |PHP|
		<IfModule !mod_php6.c>
			php_admin_flag safe_mode |SAFE_MODE|
		</IfModule>
		php_admin_value sendmail_path '/usr/sbin/sendmail -t -i -f |USER|@|DOMAIN|'
|*endif|
|*if OPEN_BASEDIR="ON"|
		php_admin_value open_basedir |OPEN_BASEDIR_PATH|
|*endif|
|*if SUPHP="1"|
                suPHP_Engine |PHP|
		suPHP_UserGroup |USER| |GROUP|
|*endif|
	</Directory>
|HANDLERS|
|MIMETYPES|
	
</VirtualHost>
 
thanks you all friends that responded topic for help me.
I think i find what is wrong by help you.
There is 4 virtual host2 files in /usr/local/directadmin/data/templates/custom/ .
I only edited one file!
Now i edited all virtual host 2 files
and add
#SuexecUserGroup |USER| |GROUP|
RMode config
RUidGid |USER| |GROUP|
RGroups apache
to all
I think it will solve the problem.
 
Probably yes, cause if you didnt edited all the secure zones wasnt using mod_ruid2 and should be the cause of your problem.

Regards
 
I edited all 4 virtual host2 files and problem solved.
thanks a lot for helping me.
 
Follow Up for SSL Forbidden Error

Hey I just wanted to do a follow up on the SSL Forbidden Error, I followed all of these steps and did the mod_ruid2 and it still didn't work.

I left out one important thing, that I figured out after looking at apache error logs.

http://help.directadmin.com/item.php?id=363

You need to put the modifications

nano -w virtual_host2.conf
## replace line: SuexecUserGroup |USER| |GROUP|
## replace with: #SuexecUserGroup |USER| |GROUP|
## Add the lines below under the just replaced line
RMode config
RUidGid |USER| |GROUP|
RGroups apache

Into EVERY virtualhost file in the /usr/local/directadmin/data/templates/custom/
directory after when doing the mod_ruid2 modification.
 
Back
Top