Linux - SoftwareThis forum is for Software issues.
Having a problem installing a new program? Want to know which application is best for the job? Post your question in this forum.
Notices
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
Get a virtual cloud desktop with the Linux distro that you want in less than five minutes with Shells! With over 10 pre-installed distros to choose from, the worry-free installation life is here! Whether you are a digital nomad or just looking for flexibility, Shells can put your Linux machine on the device that you want to use.
Exclusive for LQ members, get up to 45% off per month. Click here for more info.
Hi all
I want to redirect some http requests -that send to port 80- to port 443 in apache without changing their URLs.
for example redirect http://192.168.2.100/cardService to port 443 instead of port 80.
Can I do this ? if yes how can I do this?
thanks
Dear bathory
I added the lines that you introduced, but when I check access_log , http request does'nt redirect to https request yet. although I added the following lines to httpd.conf.
<IfModule mod_rewrite.c>
<IfModule mod_rewrite.c>
RewriteLog /var/log/httpd/rewrite_log
RewriteLogLevel info
<Directory "/svr/www/htdocs/CardServices/controller" >
RewriteEngine on
Options +FollowSymLinks
Order allow,deny
Allow from all
RewriteCond %{SERVER_PORT} !^443$
RewriteRule ^/(.*) https://%{SERVER_NAME}%{REQUEST_URI} [L,R]
</Directory>
but it doesn't work yet. just Rewritelog was made but it is empty. how can we sure that RewriteEngine is realy ON or Re-write module works correctly?
Dear bathory
thanks for spending time to answer my question. I have another problem. In our web application we don't use get method, infact we closed get request but when I redirect our http request to https, get method is used instead of post. before redirection to https, these request works correctly (post method is used) but after redirection these request don't work correctly (get mothod is used).
Can we set some parameters until post method is used while redirection to https instead of get method.
Best Regards
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.