Docs‎ > ‎CA Live API Creator‎ > ‎Security‎ > ‎Authentication‎ > ‎

Hello World Authentication Provider

The Hello World Authentication Provider has been created to demonstrate the process of creating, installing and using a custom JavaScript authentication provider.
The sample authentication provider (HelloWorldAuthenticationProvider.js) contains a lot of comments and should give you a good idea of how to implement your own.

Overview of Process

  1. Download attached files and place in a convenient directory.
  2. Install a Java runtime, Java 1.6 or later is required
  3. From the command line, execute: java -version        (verify java version and functionality)
  4. ./hw.sh      runs a simple hw.js test stub which invokes the auth provider locally outside of the API Server. When you are developing your own provider, this provides a quick turn-around environment.  The full capabilities of the server are not available.
  5. Upload HelloWorldAuthenticationProvider.js to 'Your Libraries' on the Project tab and mark the library as Used.
  6. On the 'Authentication Providers' tab, add a new provider and select the JavaScript Authentication Method.  Enter a convenient name and description
  7. Enter 'helloWorldAuthenticationProviderCreate' as the name of the function. (Note the small 'h')
  8. Press the 'Save' button
  9. The two configuration parameters should be shown (see screen shot below)
  10. Press Save
  11. On the Settings tab for the project, select the new provider and save
  12. You should now be able to use your authentication provider by calling the @authentication service. An easy way to test this is using the command line.


ċ
EspressoAuthenticationTest.jar
(5k)
Unknown user,
May 15, 2014, 9:18 AM
ċ
HelloWorldAuthenticationProvider.js
(4k)
Max Tardiveau,
Jul 21, 2014, 3:25 PM
ċ
commons-logging-1.1.1.jar
(59k)
Unknown user,
May 15, 2014, 9:18 AM
ċ
httpclient-4.2.5.jar
(423k)
Unknown user,
May 15, 2014, 9:18 AM
ċ
httpcore-4.2.4.jar
(222k)
Unknown user,
May 15, 2014, 9:18 AM
ċ
hw.js
(2k)
Unknown user,
May 15, 2014, 9:18 AM
ċ
hw.sh
(0k)
Unknown user,
May 15, 2014, 9:18 AM
ċ
rhino-1.7R4.jar
(1108k)
Unknown user,
May 15, 2014, 9:18 AM