Skip to main content

Posts

Showing posts from March, 2016

Run WSO2 Identity Server inside the docker container

Docker is a light weight container which runs on any computer or any cloud. It runs as an isolated process on the host operating system and its easier to create, deploy and run application. It is bit like a virtual machine, but it has different architectural approach which allow us to portable and efficient development. You can install docker using this documentation  on Linux. Step 1 :- You need to create a docker file. I have provided a simple docker file which use to copy identity server in to a docker image. Please copy below two lines in to a new file and modify file name as 'Docker'. I'm creating a directory 'is500image' somewhere  and put this file in to that directory. Sample Dockerfile to create a docker image with WSO2 IS 5.0.0. FROM cogniteev/oracle-java:java7 ADD ./wso2is-5.0.0.tar.gz /opt/wso2 Step 2 :- its better to create a tar.gz file using below commands. tar.gz file unzip its contend when its coping to docker image. You may creat

Invoke admin services in wso2 identity server via HTTP instead of HTTPS

It is possible to access WSO2 identity server over HTTP protocol. But Its not recommended in production environment. When you enable HTTP protocol, you can access admin console using different port(9763) Step 1 :-  Open carbon.xml file which is located in <IS_HOME>/repository/conf directory and do below changes <EnableHTTPAdminConsole> true </EnableHTTPAdminConsole> You can log in to the management console using this url  http://localhost:9763/carbon/admin/login.jsp If you want to expose all WSO2 admin services via HTTP, you need to  enable following property in carbon.xml file. It is also commented by  default. <HttpAdminServices>*</HttpAdminServices> this is commented by default and you have to uncomment the line. These configurations are enough for WSO2 identity server 5.0.0. If you need to enable http for wso2 identity server 5.1.0, you have to modify web.xml file as mentioned in Step 2. Step 2 :- Modify the web.xml f

How to use RESTclient to get access token from WSO2 Identity Server

Access token can be retrieve in different ways. This blog is explained the way you can get access token using cURL command. As a next step, I'm going to explain the way you can retrieve an access token using Advance REST client(Firefox plugin). Step 1 :- First create a service provider in WSO2 Identity server. Register a new application by providing callback url and allowed grant types. You must tick a password grant type because I'm going to get an access token using password grant type After above configurations are done. You can see the generated client key and secret as below Now you have client key and client secret for particular application. That means, you have completed the first step. Step 2 :- Get the base64 encoded value for client key and secret. before get the encoded value, client key and secret should be separated by colon. <client_key>:<client_secret> VbUbPR4a5c8wSIlRFfVq9j3UYCka:KBkyfyEtop2pOvOuiODCZIHqN0Ma This