LinuxQuestions.org
Review your favorite Linux distribution.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie
User Name
Password
Linux - Newbie This Linux forum is for members that are new to Linux.
Just starting out and have a question? If it is not in the man pages or the how-to's this is the place!

Notices


Reply
  Search this Thread
Old 09-25-2011, 09:39 PM   #1
BernardLinux
LQ Newbie
 
Registered: Sep 2011
Location: Malaysia
Posts: 21

Rep: Reputation: Disabled
Hide IPv6 address in URL.


Hello, i am configuring Apache on CentOS and what i want to do is to hide the ip address whenever the user inserts IP address to view my web. lets say my website ip addr is 172.16.40.86 and its domain name is example.com.

the thing is, when i input
Code:
http://172.16.40.86
the IP address will stay there and i want it to be hidden and tell apache to automatically change it
Code:
http://example.com

here, i used this lines
Code:
RewriteEngine On
    RewriteCond %{HTTP_HOST} ^172\.16\.40\.86
Now, the problem is, how can i do it for IPv6 address?
Please help. thanks

Last edited by BernardLinux; 09-25-2011 at 09:41 PM.
 
Old 09-26-2011, 12:33 AM   #2
EricTRA
LQ Guru
 
Registered: May 2009
Location: Gibraltar, Gibraltar
Distribution: Fedora 20 with Awesome WM
Posts: 6,805
Blog Entries: 1

Rep: Reputation: 1297Reputation: 1297Reputation: 1297Reputation: 1297Reputation: 1297Reputation: 1297Reputation: 1297Reputation: 1297Reputation: 1297
Hello,

Please don't double-post your question/problem. That will only confuse you and us on to where the conversation is taking place. Stick to one thread per question. I've reported your other thread since it's a duplicate of this one.

Kind regards,

Eric
 
Old 09-26-2011, 12:39 AM   #3
EricTRA
LQ Guru
 
Registered: May 2009
Location: Gibraltar, Gibraltar
Distribution: Fedora 20 with Awesome WM
Posts: 6,805
Blog Entries: 1

Rep: Reputation: 1297Reputation: 1297Reputation: 1297Reputation: 1297Reputation: 1297Reputation: 1297Reputation: 1297Reputation: 1297Reputation: 1297
Hello,

What's keeping you from writing the same condition for your IPv6 address? You did it for the IPv4 one, so it's just another regex in my opinion. Did you try it? Sounds only logical to me that if you can write a regex to change the IPv4 that you could use the same for the IPv6 version.

Kind regards,

Eric
 
Old 09-26-2011, 01:18 AM   #4
BernardLinux
LQ Newbie
 
Registered: Sep 2011
Location: Malaysia
Posts: 21

Original Poster
Rep: Reputation: Disabled
Thanks for reminding. i thought i posted on two threads so i can get fast and more replies. sorry.

yea i did it for IPv4, and im just wondering how to do it for ipv6? because it is my task given by my supervisor to test Apache using IPv6 and if i know extra knowledge about this mod_rewrite method, it would be helpful.

thanks.

Regards,
Bernard.
 
  


Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
Hide hostname in url nahom2112 Linux - Newbie 4 12-27-2009 05:48 PM
Configure Url to hide directory in apache immortaltechnique Linux - Networking 1 03-03-2008 11:36 PM
How to set IPv6 address on IPv6 router tlemons Linux - Networking 3 09-17-2007 01:25 PM
Hide my ip address Richie55 Linux - General 5 01-31-2006 03:41 PM
hide ip address treotan Linux - Networking 2 08-02-2004 08:02 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie

All times are GMT -5. The time now is 07:23 AM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration