Documentation

Trace:

Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Both sides previous revision Previous revision
Next revision
Previous revision
applications:rest_extensions [2019/03/08 10:00]
admin
applications:rest_extensions [2020/07/08 12:55] (current)
cduncan articles
Line 1: Line 1:
 ~~NOTRANS~~ ~~NOTRANS~~
 ~~NOPDF~~ ~~NOPDF~~
-~~Title: REST extensions~~+~~Title: REST Extensions~~
  
-=== Public ​services ​=== +=== Public ​Services ​=== 
-The [[jvx:​common:​util:​rest|REST API of JVx]] offers a great solution for generic services accessible via REST. But the standard access is protected by BASIC authentication and sometimes it's important to offer public services without authentication. This isn't possible with standard JVx authentication implementations. Our application framework enables you to do really cool things with JVx' REST API.+The [[jvx:​common:​util:​rest|REST API of JVx]] offers a great solution for generic services accessible via REST. However, ​the standard access is protected by BASIC authenticationand sometimes it's important to offer public services without authentication. This isn't possible with standard JVx authentication implementations. Our application framework enables you to do really cool things with JVx' REST API.
  
-To enable public REST services, first configure your REST zone to use the forwarding authentication mode. Simply add following to your Deployment desceriptor ​(web.xml):+To enable public REST services, first configure your REST zone to use the forwarding authentication mode. Simply add the following to your deployment descriptor ​(web.xml):
  
 <code xml> <code xml>
Line 43: Line 43:
 </​file>​ </​file>​
  
-The authentication type defines that the configured SecurityManager will be used for authentication without pre-authentication with BASIC authentication. Usually, the BASIC authentication will be done before using the SecurityManager (e.g. authtype set to basic). The forward mode can be used to implement Single-Sign-On or no-authentication at all.+The authentication type defines that the configured SecurityManager will be used for authentication without pre-authentication with BASIC authentication. Usually, the BASIC authentication will be done before using the SecurityManager (e.g.authtype set to basic). The forward mode can be used to implement Single-Sign-On or no-authentication at all.
  
-In our case, we performa an anonymous authentication with a pre-configured user. This enables you to configure the user with roles and offer Public ​REST services without changing the appliation.+In our case, we performa an anonymous authentication with a pre-configured user. This enables you to configure the user with roles and offer public ​REST services without changing the application.
  
 To enable anonymous authentication,​ use the [[applications:​anonymous_connection|AnonymousDBSecurityManager]] in your config.xml: To enable anonymous authentication,​ use the [[applications:​anonymous_connection|AnonymousDBSecurityManager]] in your config.xml:
Line 53: Line 53:
   <​class>​com.sibvisions.apps.server.security.AnonymousDBSecurityManager</​class>​   <​class>​com.sibvisions.apps.server.security.AnonymousDBSecurityManager</​class>​
   <​accesscontroller>​com.sibvisions.apps.server.object.DBWorkScreenAccess</​accesscontroller>​   <​accesscontroller>​com.sibvisions.apps.server.object.DBWorkScreenAccess</​accesscontroller>​
-  ​<​passwordalgorithm>​SHA</​passwordalgorithm>​+  ​...
 </​securitymanager>​ </​securitymanager>​
 </​code>​ </​code>​
Line 65: Line 65:
 </​code>​ </​code>​
  
-In above URL, the application is available in the context **webapp**. The application name is **myapp** and the Session LCO contains the method:+In the above URL, the application is available in the context **webapp**. The application name is **myapp** and the **Session** LCO contains the method:
  
 <code java> <code java>
Line 86: Line 86:
 And the LCO code: And the LCO code:
  
-<​file ​xml Anonymous.java>​+<​file ​java Anonymous.java>​
 @StrictIsolation @StrictIsolation
 @Replacement(name = "​Public"​) @Replacement(name = "​Public"​)
Line 97: Line 97:
 } }
 </​file>​ </​file>​
-This class doesn'​t extend the Session LCO and it's an [[jvx:​server:​lco:​session_isolation|Isolated LCO]]. ​And the class-name got a [[jvx:​server:​lco:​objects_rename|Replacement]] with the name Public.+This class doesn'​t extend the Session LCOand it's an [[jvx:​server:​lco:​session_isolation|Isolated LCO]]. ​Additionally, ​the class name got a [[jvx:​server:​lco:​objects_rename|Replacement]] with the name Public.
  
 With this configuration,​ our REST call will be changed to: With this configuration,​ our REST call will be changed to:
This website uses cookies for visitor traffic analysis. By using the website, you agree with storing the cookies on your computer.More information