0

We have Zimbra 8.0.3 OS edition server. Our server has several A-entries in DNS-server. Let's suppose they are aaa.mydomain.com, bbb.mydomain.com and ccc.mydomain.com. Could anybody say what I should do to redirect users to page 404 when they use bbb.mydomain.com, ccc.mydomain.com and server IP-address but give them access to mail web-client if they use aaa.mydomain.com?

Thanks in advance.

ArtRet
  • 11
  • 1
  • Sorry. I forgot to tell I was using Jetty. – ArtRet May 24 '13 at 15:27
  • Do you really want a 404 or to redirect them to the right location using a 302 redirect? Also is jetty out in front or is apache in the mix somewhere? You will need to pick where you want to handle the redirects or 404. – jeffatrackaid May 24 '13 at 16:20
  • I don't really know if jetty is behind apache or not in zimbra. I haven't much experience with web servers. And yes, I want 404 page to be used. – ArtRet May 24 '13 at 17:01

2 Answers2

0

You could do something like this:

  RewriteEngine on
  RewriteCond %{HTTP_REFERER} ^bbb.mydomain\.com$ [NC]
  RewriteRule .*  - [R=404]

You could also try a general forbidden error, like this:

  order allow,deny
  deny from bbb.mydomain.com
  allow from all
0

So I have solved this problem. You should add following lines into jetty.xml.in in directive < New id="zimbra" class="org.eclipse.jetty.webapp.WebAppContext" >...< /New> :

   <Set name="virtualHosts">
       <Array type="java.lang.String">
         <Item>aaa.mydomain.com</Item>
       </Array>
   </Set>

Thanks everyone =)

ArtRet
  • 11
  • 1