Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 8483517
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 10, 20262026-06-10T20:07:36+00:00 2026-06-10T20:07:36+00:00

I made a CMS application using JSP and servlet. I am not using any

  • 0

I made a CMS application using JSP and servlet. I am not using any kind of framework. The CMS has 2 parts:

  1. Front end
  2. Admin (Back end)

If I hosted it on www.example.com, for example, then all my frond end site will show for all users.

But www.example.com/admin must be accessible from a couple of IP addresses. Not from all the users.

I found these links:

  • link 1
  • link 2
  • Stack Overflow link

Link 1 looks bit confusing and Link 2 looks good, but I am not using JBoss.

In the Stack Overflow link they did not mention how to use it.

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-10T20:07:37+00:00Added an answer on June 10, 2026 at 8:07 pm

    As far as I understand from your question you use the Apache Tomcat as a web server. In that case use Remote Address Filter to restrict access by IP address. It allows comparing IP of the requesting client with regular expressions to either allow or prevent the request based on the results of the comparison.

    If you use Tomcat 7 you need use class RemoteAddrFilter and define regular expressions for necessary IP in the application’s configuration file web.xml:

    <filter>
       <filter-name>Remote Address Filter</filter-name>
       <filter-class>org.apache.catalina.filters.RemoteAddrFilter</filter-class>
       <init-param>
          <param-name>allow</param-name> <!-- or deny -->
          <param-value>10\.10\.1[12]\..*</param-value> <!-- regexp for your ip adress -->
       </init-param>
    </filter>
    <filter-mapping>
       <filter-name>Remote Address Filter</filter-name>
       <url-pattern>*/admin</url-pattern> <!-- the url of your admin page -->
    </filter-mapping>
    

    You can use hardcoded specific IP address or regular expression patterns. But in some cases regular expressions gives you a lot of flexibility in validation of addresses.

    And if you use 6 or 5 version of Tomcat you need use class RemoteAddrValve and define following line in Tomcat’s configuration file server.xml:

    <Valve className=”org.apache.catalina.valves.RemoteAddrValve” allow=”10\.10\.1[12]\..*”/> 
    

    or

     <Valve className="org.apache.catalina.valves.RemoteAddrValve"
        deny="86.57.158.37, 213.117.195.*, 124.86.42.*" /> 
    

    More information about using request filter valves.

    And interesting article about securing the administrative web apps with Tomcat.

    And by the way there’s convenient to not deny requests from localhost for testing. So it makes sense to add 127\.0\.0\.1 to your allowable range of IP adresses.

    But don’t forget that in some cases a proxy server can be used to get around the IP block. Apply also login authentication for better security.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I have made a kind of CMS using CodeIgniter. It loads the page content
I made a small page ( http://www.ovlu.li ) using CMS Made Simple ( http://www.cmsmadesimple.org/
I have been using TinyMCE WYSIWYG in CMSMS(CMS Made simple), its working in all
I'm currently working on a home-made full front-office 100% javascript CMS of ours, and
I am quite new to CMS MAde Simple. I am not able to understand
Im trying to upgrade an old project made using django 1.2 / django-page-cms 1.2
im working with a cms made a few years ago in asp/vbscript (old asp)
Here's what I have: Custom-made C# CMS where the content is stored in a
I'm maintaining a CMS where I have this feeling it was made in the
I made an application that passes trough an XML file and extracts the entries

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.