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

  • Home
  • SEARCH
  • 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 8050773
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 5, 20262026-06-05T07:09:17+00:00 2026-06-05T07:09:17+00:00

I want to implement a basic RESTful service using Tomcat. The API requires authorisation

  • 0

I want to implement a basic RESTful service using Tomcat. The API requires authorisation before it can be used. Authorisation will be achieved by requesting an account ‘resource’ e.g

some.domain.com/rest/accounts?user=ABC&password=XYZ

If the credentials are valid, an appropriate account resource will be retuned as JSON or an empty response of type 403 will be returned. After authorisation is performed, the client can then access the API (for example):

some.domain.com/rest/secure/bookings
some.domain.com/rest/secure/friends

However I feel lost with all the options for implementation. I know I want to use Spring, but Jackson seems simpler and easier for returning JSON objects.

Questions:

  1. Should I implement a Spring Controller even though the class which uses Jackson is kind of a controller too? Or if I use Jackson is there no need for a Sping controller?

  2. Should authentication be performed using Spring-Security, Tomcat filters, or AOP with Spring?

There seems to be so many ways to do things, but my priority is to keep things simple.

  • 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-05T07:09:17+00:00Added an answer on June 5, 2026 at 7:09 am

    Probably the most brain-damaged way to perform authentication I have ever seen. Authentication is not the concern of the REST API but of the underlying framework/server with Basic, Digest, Negotiate, etc. As duffymo already said, Spring Security is the most natural way to do so.

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

Sidebar

Related Questions

I want to implement basic server push mechanism using websockets in netty ( not
I want to implement basic authentication using username and password validation in my asmx
I want to implement basic shopping cart functionality in my Rails app....are there any
I want to implement a basic search/replace translation table in C; that is, it
I want to implement basic spell checking in a Notepad clone project I'm doing.
I've got a WCF service (basicHttpBinding, basic authentication, IIS 6.0) on which I want
I want to implement HTTP basic authentication on my staging server, but only for
I want to implement HTTP Basic Authentication for my web services, but I also
I want to implement two features apart from the ones in Basic View of
What I want to do is implement some basic security by checking not only

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.