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 8944279
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 15, 20262026-06-15T11:59:18+00:00 2026-06-15T11:59:18+00:00

I have a RESTful webservice which communicates over HTTPS. I want to prevent other

  • 0

I have a RESTful webservice which communicates over HTTPS. I want to prevent other developers from calling the API. The API sits in front of a database which pulls data from a number of sources so i want to have control over who uses it. Using a login page is not an option

I’ve looked at Spring-security and OAuth however neither offers exactly what I need. I don’t want to place a login page in front of the web service instead I just want to return a 400 or 401 http code when an unknown application attempts to call my service.

Can anyone recommend how i can implement this?

Outcome Thanks for feedback on this question. In the end i resorted to using an Apache module called mod_authz_host which allows you to restrict HTTP patterns to specific domains. While it is possible to spoof the domain this was for an internal app so the security requirement is more relaxed. I’ve includes a snippet below with details of how to use the Apache module

Include the following inside a Virtual host

<Location /yourProtectedServices/ws>
 Order deny,allow
 Deny from all
 Allow from trusteddomain.com
</Location>
  • 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-15T11:59:19+00:00Added an answer on June 15, 2026 at 11:59 am

    In your internal system you can create a list of Applications that have access with access tokens. Only developers/client apps with these authorised access tokens will then have access. The catch on this is if the client app source code is viewable by others.

    E.g. if someone created an Android Application with the access token in the code it could be reverse engineered when it is distributed in the app store.

    Update:
    For a more in depth view regarding security.
    http://www.thebuzzmedia.com/designing-a-secure-rest-api-without-oauth-authentication/

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

Sidebar

Related Questions

I have a restful webservice which receives some structured data which is put straight
I have a ReSTful web service which needs to parse locale-sensitive data from the
Over the past two weeks i have been developing a jersey RESTful webservice and
I have a RESTful webservice which i can successfully ping on the published server
I have a RESTful webservice which receives JSON and it deserialises it into a
I currently have a RESTful webservice which recognises a client via it's session. I
I have a restful webservice for which iam writing a new method call. The
I have a RESTful web service which runs on Glassfish Application Server. When I
I have a restful web service which can deal with DTOs in json format
I have created a RESTful PHP web service using Lithium which contains comments, each

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.