Unfortunately, the core of Pentaho 5 it's totally different from Pentaho 4.8. So, the way to authenticate the user used by Pentaho Servlet Integrator cannot be used any more in the Pentaho 5.
The Integrator Plugin for Pentaho 5 is a new implementation with the same idea, but that works in the Pentaho 5 and was developed as a pentaho plugin instead of a servlet.
Note: The plugin was not tested in the Pentaho versions prior than 5.4.
How does it work ?
- First, the user authenticates on their application. From some menu, he/she asks to access some resource on the Pentaho, such as, a report or a dashboard.
- Second, the application must maintain a common database table and insert a new record with the username / tokenid / url.
username: a pentaho username to be used.
tokenid: in our case we use jsessionid as token.
url: the url from the resource on the Pentaho Server coded in base64.
Note: for the url doesn't use the http://server:port. Example:
- Third, after the application insert the record it must send a browser redirect to
- Then, Pentaho server will decode the url and try do a select on the tokensbi table to filter the username to be used in the Pentaho session.
- So, If tokenid/url is valid, the Pentaho server will create an authenticated session and redirect the user to the Pentaho resource.
How to install ?
Use the Marketplace to install it.
How to use it ?
- Create a new JNDI connection in the Pentaho.
- Configure the new JNDI name into integrator.properties file.
- Do the proper configurations in the application.
Using a node.js app sample
To test the plugin, you can use an node.js app sample available in the folder resources/app-sample.
- Install node.js
- Install packages. In the folder app-sample execute npm install
- Configure the postgresConnectionString property in the config.js file to access the same database configured in the JNDI connection.
- Run the app: node server.js
- Test it: http://localhost:1010
If somebody sees any improvement opportunity, please feel free to suggest and contribute with the project.
Enjoy it !!!