<?xml version="1.0" encoding="utf-8"?>
<rss xmlns:atom="http://www.w3.org/2005/Atom" version="2.0"><channel><title>Answers to: REST service security</title><link>https://answers.axonivy.com/questions/1858/rest-service-security</link><description>&lt;p&gt;Hello All,&lt;/p&gt;
&lt;p&gt;What is the security context of the new REST services ?
How to get/check the user that is consuming them ?&lt;/p&gt;
&lt;p&gt;Thanks a lot !&lt;/p&gt;
&lt;p&gt;Best Regards,
Yordan Yunchov&lt;/p&gt;</description><atom:link href="https://answers.axonivy.com/questions/1858/rest-service-security" rel="self"></atom:link><language>en</language><lastBuildDate>Mon, 04 Jul 2016 15:30:15 -0400</lastBuildDate><item><title>Comment by Stelt0 on Reto Weiss's answer</title><link>https://answers.axonivy.com/questions/1858/rest-service-security#1861</link><description>&lt;p&gt;Thanks Reto !&lt;/p&gt;</description><dc:creator xmlns:dc="http://purl.org/dc/elements/1.1/">Stelt0</dc:creator><pubDate>Mon, 04 Jul 2016 15:30:15 -0400</pubDate><guid>https://answers.axonivy.com/questions/1858/rest-service-security#1861</guid></item><item><title>Answer by Reto Weiss</title><link>https://answers.axonivy.com/questions/1858/rest-service-security/1860</link><description>&lt;p&gt;The REST service provided by Axon.ivy are be default protected by HTTP BASIC Authentication. We suggest that you use https to communicate with the provided services since HTTP BASIC sends passwords in cleartext. All Axon.ivy users of an application can be used to authenticate against the REST service.&lt;/p&gt;
&lt;p&gt;Since 6.4 you can customize the security for each service or even on single methods:&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;&lt;code&gt;@javax.annotation.security.PermitAll&lt;/code&gt;: allows unauthenticated access to anonymous users&lt;/li&gt;
&lt;li&gt;&lt;code&gt;@javax.annotation.security.RolesAllowed&lt;/code&gt;: users must be authenticated and own the defined roles&lt;/li&gt;
&lt;li&gt;&lt;code&gt;@javax.annotation.security.DenyAll&lt;/code&gt;: nobody is allowed to invoke this service&lt;/li&gt;
&lt;li&gt;See the &lt;strong&gt;SecureService&lt;/strong&gt; in the &lt;strong&gt;ConnectivityDemos&lt;/strong&gt; for a demo:&lt;/li&gt;
&lt;li&gt;Or look at the Jersey chapter about secure annotations. &lt;a href="https://jersey.java.net/documentation/latest/security.html#annotation-based-security"&gt;https://jersey.java.net/documentation/latest/security.html#annotation-based-security&lt;/a&gt;&lt;/li&gt;
&lt;/ul&gt;
&lt;p&gt;&lt;img alt="alt text" src="http://answers.axonivy.com/upfiles/secureRestService.PNG"&gt;&lt;/p&gt;</description><dc:creator xmlns:dc="http://purl.org/dc/elements/1.1/">Reto Weiss</dc:creator><pubDate>Mon, 04 Jul 2016 15:24:18 -0400</pubDate><guid>https://answers.axonivy.com/questions/1858/rest-service-security/1860</guid></item></channel></rss>