I need to prevent all access to a java spring rest service, except for request made from specific url. antMatchers don't seem to address this type of situation.
I would appreciate it anyone could point me into the right direction.
When you say "from specific url" what does that mean? Generally you check request based on IP address they are coming from. A URL cannot request another URL technically. You can use referer header but I wouldn't recommend that as it can be easily set to anything...