[Dev] Create stand-alone testing tool using JMeter

2017-11-07 Thread Kasun Bandara
Hi All,

I'm recently working on developing *Scenario Testing Framework *as a
stand-alone application. The problem encountered to me was, even though I
use JMeter API to run test suites it still requires JMeter home path in
the local installation. Is there a workaround to run JMeter tests only
using JMeter jars?

There is one alternative exists that run the tests using maven, but here
I'm interested in executing the test using JMeter APIs as I have to get
back test results for further analysis.

Thanks and Regards,
-- 
*Kasun Bandara*
Software Engineer | WSO2

Mobile: +94715787004 <+94%2071%20578%207004>

___
Dev mailing list
Dev@wso2.org
http://wso2.org/cgi-bin/mailman/listinfo/dev


[Dev] [IS][SAML] Using different cert for SAML response signing

2017-11-07 Thread Danushka Fernando
Hi All

Currently in Identity Server we use server's primary keystore's primary
cert for response signing. Is it possible to use a different cert for this
somehow?

Thanks & Regards
Danushka Fernando
Associate Tech Lead
WSO2 inc. http://wso2.com/
Mobile : +94716332729
___
Dev mailing list
Dev@wso2.org
http://wso2.org/cgi-bin/mailman/listinfo/dev


[Dev] Trying to run a jmeter script through a testng Test and fails

2017-11-07 Thread Chamara Ariyarathne
I'm trying to run a jmeter script with the following Test method in testng
and my maven build fails like following. Any help in resolving this matter
will be appreciated.

*Method: *

@Test
public void runJmeter() throws Exception {
StandardJMeterEngine jmeter = new StandardJMeterEngine();

JMeterUtils.setJMeterHome("/home/chamara/Programs/apache-jmeter-3.2
");

JMeterUtils.loadJMeterProperties("/home/chamara/stress-test-framework/src/test/resources/CUSTOM/user.properties");
JMeterUtils.initLogging();
JMeterUtils.initLocale();

SaveService.loadProperties();

FileInputStream in = new
FileInputStream("/home/chamara/stress-test-framework/src/test/jmeter/CUSTOM/Concurrency_Thread_Group.jmx");
HashTree testPlanTree = SaveService.loadTree(in);
in.close();

jmeter.configure(testPlanTree);
jmeter.run();


}

*Failure: *

---
 T E S T S
---
Running org.wso2.stress.StressTest
Configuring TestNG with:
org.apache.maven.surefire.testng.conf.TestNG652Configurator@2db0f6b2
INFO2017-11-07 18:35:18.029 [jmeter.e] (): Listeners will be started
after enabling running version
INFO2017-11-07 18:35:18.041 [jmeter.e] (): To revert to the earlier
behaviour, define jmeterengine.startlistenerslater=false
Tests run: 1, Failures: 1, Errors: 0, Skipped: 0, Time elapsed: 0.389 sec
<<< FAILURE!
runJmeter(org.wso2.stress.StressTest)  Time elapsed: 0.199 sec  <<< FAILURE!
java.lang.NullPointerException
at
org.apache.jmeter.engine.StandardJMeterEngine.configure(StandardJMeterEngine.java:164)
at org.wso2.stress.StressTest.runJmeter(StressTest.java:31)

-- 
*Chamara Ariyarathne*
WSO2 Inc; http://www.wso2.com/
Mobile; *+94772786766*
___
Dev mailing list
Dev@wso2.org
http://wso2.org/cgi-bin/mailman/listinfo/dev


Re: [Dev] Newly created API does not appear in the API manager with the pre-packaged Identity Server as a Key Manager

2017-11-07 Thread Chamalee De Silva
Hi Thomas,

Can you clear out the H2 database and clear the registry mount path once
and try again ?
This might be an issue due to intermediate incorrect mounting
configurations as described in [1].


[1] https://wso2.org/jira/browse/APIMANAGER-2174

On Tue, Nov 7, 2017 at 9:43 PM, Thomas LEGRAND  wrote:

> Hello,
>
> I have my API manager which is configured to use the Identity Server as
> Key Manager. But, on the API manager publisher, when I create a new API
> from a swagger file or using the assistant (for the worldbank tuto), I
> don't see any of my API in the list. However, I can see that XML files are
> created via the log of the API manager :
>
> TID: [-1234] [] [2017-11-07 17:04:39,159]  INFO
>> {org.apache.synapse.rest.API} -  Initializing API: admin--WorldBank:v1.0.0
>> {org.apache.synapse.rest.API}
>>
>
> But nothing on my screen:
>
> [image: Images intégrées 1]
>
> I am connected as admin (the default user) and I can't even bind my API to
> an application on the API manager store :/
>
> I double-checked the configuration but I can see an error at the startup
> of the API manager :
>
> TID: [-1234] [] [2017-11-07 17:04:02,197] ERROR {org.wso2.carbon.registry.
> core.internal.RegistryCoreServiceComponent} -  Unable to create fixed
> remote mounts. {org.wso2.carbon.regi
> stry.core.internal.RegistryCoreServiceComponent}
> org.wso2.carbon.registry.core.exceptions.RegistryException: An exception
> occurred while executing handler chain. null
> at org.wso2.carbon.registry.core.jdbc.handlers.HandlerManager.
> delete(HandlerManager.java:2649)
> at org.wso2.carbon.registry.core.jdbc.handlers.
> UserDefinedHandlerManager.delete(UserDefinedHandlerManager.java:215)
> Caused by: java.lang.NullPointerException
> at org.wso2.carbon.registry.core.jdbc.handlers.builtin.
> MountHandler.delete(MountHandler.java:490)
> at org.wso2.carbon.registry.core.jdbc.handlers.HandlerManager.
> delete(HandlerManager.java:2627)
> ... 50 more
>
> - Do you have any idea why this error occurs?
> - Is this error linked to the fact I can't see my newly created APIs?
> - CAn you help me, please?
>
> Regards,
>
> Thomas
>
> ___
> Dev mailing list
> Dev@wso2.org
> http://wso2.org/cgi-bin/mailman/listinfo/dev
>
>


-- 
Thanks & Regards,

*Chamalee De Silva*
Software Engineer
*WS**O2* Inc. :http://wso2.com/

Office   :- *+94 11 2145345 <%2B94%2011%202145345>*
mobile  :- *+94 7 <%2B94%2077%202782039>1 4315942*
___
Dev mailing list
Dev@wso2.org
http://wso2.org/cgi-bin/mailman/listinfo/dev


[Dev] [IS as a KM] Where are the access tokens getting stored

2017-11-07 Thread Nuwan Silva
Hi All,

I have an APIM 2.1.0 instance with IS 5.3.0 as the Key Manager which was
setup as per [1]. So as per my understanding when tokens are generated they
should be stored in *IDN_OAUTH2_ACCESS_TOKEN *table of the WSO2AM_DB (APIM
related database).
I can generate, regenerate and invoke using the access tokens generated but
they are not stored in the mentioned table. I do see the subscriptions in
the database but no tokens.

Am I missing something here?

[1]
https://docs.wso2.com/display/AM210/Configuring+an+External+IDP+as+a+Key+Manager

Cheers,
NuwanS.
-- 


*Nuwan Silva*
*Associate Technical Lead*
Mobile: +9477 980 4543

WSO2 Inc.
lean . enterprise . middlewear.
http://www.wso2.com
___
Dev mailing list
Dev@wso2.org
http://wso2.org/cgi-bin/mailman/listinfo/dev


[Dev] [Charon] No JSON ecoding method for PatchOperation

2017-11-07 Thread Isuranga Perera
Hi All,

I need to encode a List object into a resource string. Even
though there is a decoding method in JSONDecoder which converts resource
string into List I couldn't find an encoding method.

Is there any way I can encode LIst. Appreciate any help.

Best Regards
Isuranga Perera
___
Dev mailing list
Dev@wso2.org
http://wso2.org/cgi-bin/mailman/listinfo/dev


Re: [Dev] Newly created API does not appear in the API manager with the pre-packaged Identity Server as a Key Manager

2017-11-07 Thread Bhathiya Jayasekara
Hi Thomas,

Please attach complete log files and registry.xml files of both servers.

Thanks,
Bhathiya

On Tue, Nov 7, 2017 at 9:43 PM, Thomas LEGRAND  wrote:

> Hello,
>
> I have my API manager which is configured to use the Identity Server as
> Key Manager. But, on the API manager publisher, when I create a new API
> from a swagger file or using the assistant (for the worldbank tuto), I
> don't see any of my API in the list. However, I can see that XML files are
> created via the log of the API manager :
>
> TID: [-1234] [] [2017-11-07 17:04:39,159]  INFO
>> {org.apache.synapse.rest.API} -  Initializing API: admin--WorldBank:v1.0.0
>> {org.apache.synapse.rest.API}
>>
>
> But nothing on my screen:
>
> [image: Images intégrées 1]
>
> I am connected as admin (the default user) and I can't even bind my API to
> an application on the API manager store :/
>
> I double-checked the configuration but I can see an error at the startup
> of the API manager :
>
> TID: [-1234] [] [2017-11-07 17:04:02,197] ERROR {org.wso2.carbon.registry.
> core.internal.RegistryCoreServiceComponent} -  Unable to create fixed
> remote mounts. {org.wso2.carbon.regi
> stry.core.internal.RegistryCoreServiceComponent}
> org.wso2.carbon.registry.core.exceptions.RegistryException: An exception
> occurred while executing handler chain. null
> at org.wso2.carbon.registry.core.jdbc.handlers.HandlerManager.
> delete(HandlerManager.java:2649)
> at org.wso2.carbon.registry.core.jdbc.handlers.
> UserDefinedHandlerManager.delete(UserDefinedHandlerManager.java:215)
> Caused by: java.lang.NullPointerException
> at org.wso2.carbon.registry.core.jdbc.handlers.builtin.
> MountHandler.delete(MountHandler.java:490)
> at org.wso2.carbon.registry.core.jdbc.handlers.HandlerManager.
> delete(HandlerManager.java:2627)
> ... 50 more
>
> - Do you have any idea why this error occurs?
> - Is this error linked to the fact I can't see my newly created APIs?
> - CAn you help me, please?
>
> Regards,
>
> Thomas
>
> ___
> Dev mailing list
> Dev@wso2.org
> http://wso2.org/cgi-bin/mailman/listinfo/dev
>
>


-- 
*Bhathiya Jayasekara*
*Associate Technical Lead,*
*WSO2 inc., http://wso2.com *

*Phone: +94715478185*
*LinkedIn: http://www.linkedin.com/in/bhathiyaj
*
*Twitter: https://twitter.com/bhathiyax *
*Blog: http://movingaheadblog.blogspot.com
*
___
Dev mailing list
Dev@wso2.org
http://wso2.org/cgi-bin/mailman/listinfo/dev


[Dev] Newly created API does not appear in the API manager with the pre-packaged Identity Server as a Key Manager

2017-11-07 Thread Thomas LEGRAND
Hello,

I have my API manager which is configured to use the Identity Server as Key
Manager. But, on the API manager publisher, when I create a new API from a
swagger file or using the assistant (for the worldbank tuto), I don't see
any of my API in the list. However, I can see that XML files are created
via the log of the API manager :

TID: [-1234] [] [2017-11-07 17:04:39,159]  INFO
> {org.apache.synapse.rest.API} -  Initializing API: admin--WorldBank:v1.0.0
> {org.apache.synapse.rest.API}
>

But nothing on my screen:

[image: Images intégrées 1]

I am connected as admin (the default user) and I can't even bind my API to
an application on the API manager store :/

I double-checked the configuration but I can see an error at the startup of
the API manager :

TID: [-1234] [] [2017-11-07 17:04:02,197] ERROR
{org.wso2.carbon.registry.core.internal.RegistryCoreServiceComponent} -
Unable to create fixed remote mounts. {org.wso2.carbon.regi
stry.core.internal.RegistryCoreServiceComponent}
org.wso2.carbon.registry.core.exceptions.RegistryException: An exception
occurred while executing handler chain. null
at
org.wso2.carbon.registry.core.jdbc.handlers.HandlerManager.delete(HandlerManager.java:2649)
at
org.wso2.carbon.registry.core.jdbc.handlers.UserDefinedHandlerManager.delete(UserDefinedHandlerManager.java:215)
Caused by: java.lang.NullPointerException
at
org.wso2.carbon.registry.core.jdbc.handlers.builtin.MountHandler.delete(MountHandler.java:490)
at
org.wso2.carbon.registry.core.jdbc.handlers.HandlerManager.delete(HandlerManager.java:2627)
... 50 more

- Do you have any idea why this error occurs?
- Is this error linked to the fact I can't see my newly created APIs?
- CAn you help me, please?

Regards,

Thomas
___
Dev mailing list
Dev@wso2.org
http://wso2.org/cgi-bin/mailman/listinfo/dev


Re: [Dev] CSRF token error in working with EI Management Console with Java 1.8.0_151

2017-11-07 Thread Sudharma Subasinghe
On Tue, Nov 7, 2017 at 7:01 PM, Arunan Sugunakumar  wrote:

> Hi,
>
> I seem to be getting this issue in wso2das-3.1.0 and wso2esb5.0.0 as well.
> Is there any temporary fix for this problem?
>

Did you get the issue for wso2esb 5.0.0 with JDK 1.8.0_144? Try with JDK
1.8.0_45 for wso2 esb 5.0.0 which works for me.

>
> Thanks
>
> On Mon, Nov 6, 2017 at 9:04 PM, Sudharma Subasinghe 
> wrote:
>
>> Hi Prakash,
>>
>> Still with jdk1.8.0_144, same issue happens with EI 6.1.1-update 8 pack
>>
>> On Mon, Nov 6, 2017 at 8:06 PM, Sudharma Subasinghe 
>> wrote:
>>
>>> Same thing is happening with EI 6.1.1-update 8 with JDK 1.8.0_45.
>>>
>>>
>>> On Wed, Nov 1, 2017 at 7:14 AM, Prakhash Sivakumar 
>>> wrote:
>>>


 On Tue, Oct 31, 2017 at 3:20 PM, Thejan Rupasinghe 
 wrote:

> Hi Chaminda,
>
> Seems it is an issue in the Tomcat server with that jdk update.
>
 Yes. This is happining due to a gzip decoding issue with JDK 1.8.0_151,
 which is reported in [1] .

 [1] https://bugs.openjdk.java.net/browse/JDK-8189789


> Thanks for informing.
>
> Regards,
> Thejan
>
> On Tue, Oct 31, 2017 at 2:54 PM, Chaminda Jayawardena <
> chami...@wso2.com> wrote:
>
>>
>> seems a known issue and the ESB document has been updated with the
>> info.
>>
>> [1] https://docs.wso2.com/display/ESB500/Installation+Prerequisites
>>
>> Thanks
>> Chaminda
>>
>> On Tue, Oct 31, 2017 at 10:21 AM, Thejan Rupasinghe 
>> wrote:
>>
>>> Hi all,
>>>
>>> When I'm working with EI Management Console with the latest Java 8
>>> version, 1.8.0_151 [1], following error occurred.
>>>
>>> [2017-10-30 19:14:54,210] [EI-Core]  WARN - JavaLogger potential
>>> cross-site request forgery (CSRF) attack thwarted (user:,
>>> ip:10.100.4.201, method:POST, 
>>> uri:/carbon/admin/jsp/WSRequestXSSproxy_ajaxprocessor.jsp,
>>> error:required token is missing from the request)
>>>
>>> I could not submit any form data through Management Console.
>>>
>>> I tested with EI 6.1.1 and current update, EI 6.1.1-update 7, but
>>> the same error occurred.
>>>
>>> When I use Java 1.8.0_144, everything works fine.
>>>
>>> Can anyone explain why does this happen?
>>>
>>> [1] https://java.com/en/download/
>>>
>>> Thanks,
>>> Regards,
>>> Thejan
>>> --
>>>
>>> *Thejan Rupasinghe*
>>>
>>> *Intern - Software EngineeringWSO2*
>>>
>>> *Mobile : +94 77-9020962 <+94%2077%20902%200962>*
>>> 
>>>
>>> ___
>>> Dev mailing list
>>> Dev@wso2.org
>>> http://wso2.org/cgi-bin/mailman/listinfo/dev
>>>
>>>
>>
>>
>> --
>> Thanks & Regards
>>
>> *Chaminda Jayawardena*
>> Associate Technical Lead - QA
>> WSO2 Inc. - http://wso2.com
>> +94-77-7725234 <+94%2077%20772%205234>
>>
>
>
>
> --
>
> *Thejan Rupasinghe*
>
> *Intern - Software EngineeringWSO2*
>
> *Mobile : +94 77-9020962 <+94%2077%20902%200962>*
> 
>
> ___
> Dev mailing list
> Dev@wso2.org
> http://wso2.org/cgi-bin/mailman/listinfo/dev
>
>


 --
 Prakhash Sivakumar
 Software Engineer | WSO2 Inc
 Platform Security Team
 Mobile : +94771510080 <+94%2077%20151%200080>
 Blog : https://medium.com/@PrakhashS

 ___
 Dev mailing list
 Dev@wso2.org
 http://wso2.org/cgi-bin/mailman/listinfo/dev


>>>
>>>
>>> --
>>> Sudharma Subasinghe,
>>> Software Engineer,
>>> WSO2 Inc.
>>> Email: sudhar...@wso2.com 
>>> Mobile : +94 710 565 157 <%2B94%20718%20210%20200>
>>>
>>
>>
>>
>> --
>> Sudharma Subasinghe,
>> Software Engineer,
>> WSO2 Inc.
>> Email: sudhar...@wso2.com 
>> Mobile : +94 710 565 157 <%2B94%20718%20210%20200>
>>
>> ___
>> Dev mailing list
>> Dev@wso2.org
>> http://wso2.org/cgi-bin/mailman/listinfo/dev
>>
>>
>
>
> --
> *Sugunakumar Arunan*
> Sofware Engineering - Intern | WSO2
>
> Email : aru...@wso2.com
> Mobile : 0766016272
> Web : http://wso2.com
> 
>



-- 
Sudharma Subasinghe,
Software Engineer,
WSO2 Inc.
Email: sudhar...@wso2.com 
Mobile : +94 710 565 157 <%2B94%20718%20210%20200>
___
Dev mailing list
Dev@wso2.org
http://wso2.org/cgi-bin/mailman/listinfo/dev


Re: [Dev] [IS as a KM] Where are the access tokens getting stored

2017-11-07 Thread Harsha Kumara
Hi Nuwan,

What's the data source that you configured in the identity.xml? Ideally, it
should be AM_DB.

Thanks,
Harsha

On Tue, Nov 7, 2017 at 4:41 PM, Nuwan Silva  wrote:

> Hi All,
>
> I have an APIM 2.1.0 instance with IS 5.3.0 as the Key Manager which was
> setup as per [1]. So as per my understanding when tokens are generated they
> should be stored in *IDN_OAUTH2_ACCESS_TOKEN *table of the WSO2AM_DB
> (APIM related database).
> I can generate, regenerate and invoke using the access tokens generated
> but they are not stored in the mentioned table. I do see the subscriptions
> in the database but no tokens.
>
> Am I missing something here?
>
> [1] https://docs.wso2.com/display/AM210/Configuring+an+External+
> IDP+as+a+Key+Manager
>
> Cheers,
> NuwanS.
> --
>
>
> *Nuwan Silva*
> *Associate Technical Lead*
> Mobile: +9477 980 4543 <+94%2077%20980%204543>
>
> WSO2 Inc.
> lean . enterprise . middlewear.
> http://www.wso2.com
>



-- 
Harsha Kumara
Software Engineer, WSO2 Inc.
Mobile: +94775505618
Blog:harshcreationz.blogspot.com
___
Dev mailing list
Dev@wso2.org
http://wso2.org/cgi-bin/mailman/listinfo/dev


Re: [Dev] Issue when running mysql db script - APIM analytics HA setup

2017-11-07 Thread Damith Wickramasinghe
Hi Chamalee,

Then there should be a link to that from where ever we mention to run mysql
scripts. Because person only checks/ run what's mentioned then and there.
WDYT ?

Regards,
Damith



On Tue, Nov 7, 2017 at 3:18 PM, Chamalee De Silva  wrote:

> Hi Damith,
>
> mysql5.7.sql script has been added for MySQL 5.7 and later versions of
> databases.
> This is clearly described in the documentation on setting up MySQL
> documentation in [1].
>
> If we are going to add this special note, we may have to add this
> everywhere where mysql is used.
>
> @team, What is the best option ?
>
>
> [1] https://docs.wso2.com/display/AM200/Setting+up+MySQL
>
>
> On Tue, Nov 7, 2017 at 2:20 PM, Damith Wickramasinghe 
> wrote:
>
>> Hi all,
>>
>> I'm using mysql version 5.7.20. In order to populate userdb and regdb i
>> need to run mysql scripts and i have used the scripts in APIM analytics
>> pack(mysql.sql). When run below issue arises,
>>
>> ERROR 1067 (42000): Invalid default value for 'REG_CREATED_TIME'
>> ERROR 1146 (42S02): Table 'regdb.REG_RESOURCE' doesn't exist
>> ERROR 1146 (42S02): Table 'regdb.REG_RESOURCE' doesn't exist
>> ERROR 1146 (42S02): Table 'regdb.REG_RESOURCE' doesn't exist
>> ERROR 1146 (42S02): Table 'regdb.REG_RESOURCE' doesn't exist
>> ERROR 1146 (42S02): Table 'regdb.REG_RESOURCE' doesn't exist
>> ERROR 1146 (42S02): Table 'regdb.REG_RESOURCE' doesn't exist
>> ERROR 1146 (42S02): Table 'regdb.REG_RESOURCE' doesn't exist
>> ERROR 1067 (42000): Invalid default value for 'REG_LAST_UPDATED_TIME'
>> ERROR 1146 (42S02): Table 'regdb.REG_RESOURCE_HISTORY' doesn't exist
>> ERROR 1146 (42S02): Table 'regdb.REG_RESOURCE_HISTORY' doesn't exist
>> ERROR 1146 (42S02): Table 'regdb.REG_RESOURCE_HISTORY' doesn't exist
>> ERROR 1146 (42S02): Table 'regdb.REG_RESOURCE' doesn't exist
>>
>> Searching the issue found out i need to run NOT mysql.sql but
>> mysql5.7.sql. So for wt version does the mysql.sql works ? versions other
>> than  5.7 ? IF so we need to mention this clearly in the
>> docs . I found the same issue has been occurred for a customer as well.
>> I followed [1].
>>
>> [1] - https://docs.wso2.com/display/AM210/Minimum+High+Availabilit
>> y+Deployment+for+WSO2+APIM+Analytics
>>
>> Regards,
>> Damith.
>>
>> --
>> Senior Software Engineer
>> WSO2 Inc.; http://wso2.com
>> 
>> lean.enterprise.middleware
>>
>> mobile: *+94728671315 <+94%2072%20867%201315>*
>>
>> --
>> You received this message because you are subscribed to the Google Groups
>> "WSO2 Documentation Group" group.
>> To unsubscribe from this group and stop receiving emails from it, send an
>> email to documentation+unsubscr...@wso2.com.
>> For more options, visit https://groups.google.com/a/wso2.com/d/optout.
>>
>
>
>
> --
> Thanks & Regards,
>
> *Chamalee De Silva*
> Software Engineer
> *WS**O2* Inc. :http://wso2.com/
>
> Office   :- *+94 11 2145345 <%2B94%2011%202145345>*
> mobile  :- *+94 7 <%2B94%2077%202782039>1 4315942*
>
>


-- 
Senior Software Engineer
WSO2 Inc.; http://wso2.com

lean.enterprise.middleware

mobile: *+94728671315*
___
Dev mailing list
Dev@wso2.org
http://wso2.org/cgi-bin/mailman/listinfo/dev


Re: [Dev] [IS as a KM] Where are the access tokens getting stored

2017-11-07 Thread Nuwan Silva
Yup, missed this config in the IS side. Can see the tokens. Thanks Harsha.

Cheers,
NuwanS.

On Tue, Nov 7, 2017 at 5:32 PM, Harsha Kumara  wrote:

> Hi Nuwan,
>
> What's the data source that you configured in the identity.xml? Ideally,
> it should be AM_DB.
>
> Thanks,
> Harsha
>
> On Tue, Nov 7, 2017 at 4:41 PM, Nuwan Silva  wrote:
>
>> Hi All,
>>
>> I have an APIM 2.1.0 instance with IS 5.3.0 as the Key Manager which was
>> setup as per [1]. So as per my understanding when tokens are generated they
>> should be stored in *IDN_OAUTH2_ACCESS_TOKEN *table of the WSO2AM_DB
>> (APIM related database).
>> I can generate, regenerate and invoke using the access tokens generated
>> but they are not stored in the mentioned table. I do see the subscriptions
>> in the database but no tokens.
>>
>> Am I missing something here?
>>
>> [1] https://docs.wso2.com/display/AM210/Configuring+an+External+
>> IDP+as+a+Key+Manager
>>
>> Cheers,
>> NuwanS.
>> --
>>
>>
>> *Nuwan Silva*
>> *Associate Technical Lead*
>> Mobile: +9477 980 4543 <+94%2077%20980%204543>
>>
>> WSO2 Inc.
>> lean . enterprise . middlewear.
>> http://www.wso2.com
>>
>
>
>
> --
> Harsha Kumara
> Software Engineer, WSO2 Inc.
> Mobile: +94775505618 <+94%2077%20550%205618>
> Blog:harshcreationz.blogspot.com
>



-- 


*Nuwan Silva*
*Associate Technical Lead*
Mobile: +9477 980 4543

WSO2 Inc.
lean . enterprise . middlewear.
http://www.wso2.com
___
Dev mailing list
Dev@wso2.org
http://wso2.org/cgi-bin/mailman/listinfo/dev


Re: [Dev] Issue when running mysql db script - APIM analytics HA setup

2017-11-07 Thread Mariangela Hills
- Removing dev@wso2.org

Ack for docs!

Regards,
Mariangela


*Mariangela Hills*
Associate Lead Technical Writer - WSO2, Inc. http://wso2.com
Committer and PMC member - Apache Stratos
email:mariang...@wso2.com | mobile: +94 773 500185


On Tue, Nov 7, 2017 at 3:37 PM, Damith Wickramasinghe 
wrote:

> As Harsha mentioned it should be some where common to all places.
>
> Regards,
> Damith
>
> On Tue, Nov 7, 2017 at 3:35 PM, Harsha Kumara  wrote:
>
>>
>>
>> On Tue, Nov 7, 2017 at 3:18 PM, Chamalee De Silva 
>> wrote:
>>
>>> Hi Damith,
>>>
>>> mysql5.7.sql script has been added for MySQL 5.7 and later versions of
>>> databases.
>>> This is clearly described in the documentation on setting up MySQL
>>> documentation in [1].
>>>
>>> If we are going to add this special note, we may have to add this
>>> everywhere where mysql is used.
>>>
>>> @team, What is the best option ?
>>>
>> Best option would be to point to setting up database link as it contains
>> required information.
>>
>>>
>>>
>>> [1] https://docs.wso2.com/display/AM200/Setting+up+MySQL
>>>
>>>
>>> On Tue, Nov 7, 2017 at 2:20 PM, Damith Wickramasinghe 
>>> wrote:
>>>
 Hi all,

 I'm using mysql version 5.7.20. In order to populate userdb and regdb i
 need to run mysql scripts and i have used the scripts in APIM analytics
 pack(mysql.sql). When run below issue arises,

 ERROR 1067 (42000): Invalid default value for 'REG_CREATED_TIME'
 ERROR 1146 (42S02): Table 'regdb.REG_RESOURCE' doesn't exist
 ERROR 1146 (42S02): Table 'regdb.REG_RESOURCE' doesn't exist
 ERROR 1146 (42S02): Table 'regdb.REG_RESOURCE' doesn't exist
 ERROR 1146 (42S02): Table 'regdb.REG_RESOURCE' doesn't exist
 ERROR 1146 (42S02): Table 'regdb.REG_RESOURCE' doesn't exist
 ERROR 1146 (42S02): Table 'regdb.REG_RESOURCE' doesn't exist
 ERROR 1146 (42S02): Table 'regdb.REG_RESOURCE' doesn't exist
 ERROR 1067 (42000): Invalid default value for 'REG_LAST_UPDATED_TIME'
 ERROR 1146 (42S02): Table 'regdb.REG_RESOURCE_HISTORY' doesn't exist
 ERROR 1146 (42S02): Table 'regdb.REG_RESOURCE_HISTORY' doesn't exist
 ERROR 1146 (42S02): Table 'regdb.REG_RESOURCE_HISTORY' doesn't exist
 ERROR 1146 (42S02): Table 'regdb.REG_RESOURCE' doesn't exist

 Searching the issue found out i need to run NOT mysql.sql but
 mysql5.7.sql. So for wt version does the mysql.sql works ? versions other
 than  5.7 ? IF so we need to mention this clearly in the
 docs . I found the same issue has been occurred for a customer as
 well.  I followed [1].

 [1] - https://docs.wso2.com/display/AM210/Minimum+High+Availabilit
 y+Deployment+for+WSO2+APIM+Analytics

 Regards,
 Damith.

 --
 Senior Software Engineer
 WSO2 Inc.; http://wso2.com
 
 lean.enterprise.middleware

 mobile: *+94728671315 <+94%2072%20867%201315>*

 --
 You received this message because you are subscribed to the Google
 Groups "WSO2 Documentation Group" group.
 To unsubscribe from this group and stop receiving emails from it, send
 an email to documentation+unsubscr...@wso2.com.
 For more options, visit https://groups.google.com/a/wso2.com/d/optout.

>>>
>>>
>>>
>>> --
>>> Thanks & Regards,
>>>
>>> *Chamalee De Silva*
>>> Software Engineer
>>> *WS**O2* Inc. :http://wso2.com/
>>>
>>> Office   :- *+94 11 2145345 <%2B94%2011%202145345>*
>>> mobile  :- *+94 7 <%2B94%2077%202782039>1 4315942*
>>>
>>>
>>
>>
>> --
>> Harsha Kumara
>> Software Engineer, WSO2 Inc.
>> Mobile: +94775505618 <+94%2077%20550%205618>
>> Blog:harshcreationz.blogspot.com
>>
>
>
>
> --
> Senior Software Engineer
> WSO2 Inc.; http://wso2.com
> 
> lean.enterprise.middleware
>
> mobile: *+94728671315 <+94%2072%20867%201315>*
>
> --
> You received this message because you are subscribed to the Google Groups
> "WSO2 Documentation Group" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to documentation+unsubscr...@wso2.com.
> For more options, visit https://groups.google.com/a/wso2.com/d/optout.
>
___
Dev mailing list
Dev@wso2.org
http://wso2.org/cgi-bin/mailman/listinfo/dev


Re: [Dev] How to configure single logout when multiple authentication steps involved in the authentication flow?

2017-11-07 Thread Sashika Wijesinghe
Hi Godwin,

Thanks, Hope we can implement this feature in a future release.

Regards,
Sashika

On Tue, Nov 7, 2017 at 11:48 AM, Godwin Shrimal  wrote:

> Hi Shashika,
>
> As Malithi mentioned above Google and Facebook federated authenticators
> are not supporting Single Logout at the moment. We don't have any
> workaround unless implementing the single logout feature on those federated
> authenticators.
>
> Thanks
> Godwin
>
>
> On Tue, Nov 7, 2017 at 10:07 AM, Sashika Wijesinghe 
> wrote:
>
>> Hi Malithi,
>>
>> Thanks for the response.
>>
>> Just for clarification, how does the customer's manage to do single log
>> out with external IDPs? Do we have any workaround to log out from the
>> external IDP?
>>
>> Thanks,
>> Sashika
>>
>>
>>
>> On Mon, Nov 6, 2017 at 7:57 PM, Malithi Edirisinghe 
>> wrote:
>>
>>>
>>>
>>> On Mon, Nov 6, 2017 at 7:55 PM, Malithi Edirisinghe 
>>> wrote:
>>>


 On Mon, Nov 6, 2017 at 5:14 PM, Sashika Wijesinghe 
 wrote:

> Hi All,
>
> I want to configure single log out for a scenario where multi-step
> authentication involved (basic auth and authentication via external
> identity providers).
>
> For example, I have configured Google and Facebook as the 1st step of
> authentication (I will be using "fidp" query param to select the required
> identity provider out of Google and Facebook) and 'Basic Auth' as the 2nd
> step of authentication in the 'Local and Outbound Authentication
> configurations" of the service provider. Even though I have enabled single
> log out for the service provider, it works only for the internal
> authentication via basic auth. Session of the external IDP persist, and
> when I try to log in for the second time it only redirects to authenticate
> via basic auth.
>

 This is because the logout requests are not being initiated from Google
 and Facebook federated authenticators. That implementation is missing.
 There is a JIRA reported for Google case [1].

>>>
>>> Correcting above.
>>> This is because the logout requests are not being initiated to Google
>>> and Facebook via the respective federated authenticators. That
>>> implementation is missing. There is a JIRA reported for Google case [1].
>>>
>>>

>
> May I know how to configure single log out for this scenario (multiple
> authentication steps involved with external IDP)?
>
> Any help is highly appreciated.
>
> Thanks
> Sashika
>
> --
>
> *Sashika WijesingheSoftware Engineer - QA Team*
> Mobile : +94 (0) 774537487
> sash...@wso2.com
>


 [1] https://wso2.org/jira/browse/IDENTITY-3587

 Thanks,
 Malithi.
 --

 *Malithi Edirisinghe*
 Associate Technical Lead
 WSO2 Inc.

 Mobile : +94 (0) 718176807
 malit...@wso2.com

>>>
>>>
>>>
>>> --
>>>
>>> *Malithi Edirisinghe*
>>> Associate Technical Lead
>>> WSO2 Inc.
>>>
>>> Mobile : +94 (0) 718176807
>>> malit...@wso2.com
>>>
>>
>>
>>
>> --
>>
>> *Sashika WijesingheSoftware Engineer - QA Team*
>> Mobile : +94 (0) 774537487
>> sash...@wso2.com
>>
>
>
>
> --
> *Godwin Amila Shrimal*
> Associate Technical Lead
> WSO2 Inc.; http://wso2.com
> lean.enterprise.middleware
>
> mobile: *+94772264165*
> linkedin: *https://www.linkedin.com/in/godwin-amila-2ba26844/
> *
> twitter: https://twitter.com/godwinamila
> 
>



-- 

*Sashika WijesingheSoftware Engineer - QA Team*
Mobile : +94 (0) 774537487
sash...@wso2.com
___
Dev mailing list
Dev@wso2.org
http://wso2.org/cgi-bin/mailman/listinfo/dev


[Dev] Error while updating the Ballerina Atom Plugin.

2017-11-07 Thread Imesh Chandrasiri
Hi all,

We started to update the ballerina atom plugin using the updated language
files[1]. Using antlr4 we generated the token files [2] for the lexer and
parser files. When the plugin is updated with the newly generated files, we
get the following error from atom editor, when loading a sample ballerina
file. When debugged, the error was thrown from the atom editor when the
generated *BallerinaLexer.js *file is loaded to the editor run time. In the
previous atom plugin we have generated the token files using a single
*Ballerina.G4* but now we have used two different files named,
*BallerinaLexer.G4
*and *BallerinaParser.G4. *We have compared the new and old *BallerinaLexer.js
*file and the new file contains lot of changes. Any idea on this issue?

[Enter steps to reproduce:]

1. ...
2. ...

**Atom**: 1.21.2 x64
**Electron**: 1.6.15
**OS**: Microsoft Windows 10 Pro
**Thrown From**: [language-ballerina](
https://github.com/ballerinalang/plugin-atom) package 0.8.8


### Stack Trace

Failed to activate the language-ballerina package

```
At Unexpected identifier

SyntaxError: Unexpected identifier
at Module.get_Module._compile
(~/AppData/Local/atom/app-1.21.2/resources/app/src/native-compile-cache.js:94:52)
at Object.value [as .js]
(~/AppData/Local/atom/app-1.21.2/resources/app/src/compile-cache.js:239:29)
at Module.load (module.js:488:32)
at tryModuleLoad (module.js:447:12)
at Function.Module._load (module.js:439:3)
at Module.require (/app.asar/static/index.js:47:45)
at require
(~/AppData/Local/atom/app-1.21.2/resources/app/src/native-compile-cache.js:66:33)
at /packages/language-ballerina/lib/language-ballerina.js:7:22)
at /packages/language-ballerina/lib/language-ballerina.js:155:39)
at Module.get_Module._compile
(~/AppData/Local/atom/app-1.21.2/resources/app/src/native-compile-cache.js:106:36)
at Object.value [as .js]
(~/AppData/Local/atom/app-1.21.2/resources/app/src/compile-cache.js:239:29)
at Module.load (module.js:488:32)
at tryModuleLoad (module.js:447:12)
at Function.Module._load (module.js:439:3)
at Module.require (/app.asar/static/index.js:47:45)
at require (internal/module.js:20:19)
at customRequire
(~/AppData/Local/atom/app-1.21.2/resources/app/static/:96:26)
at Package.module.exports.Package.requireMainModule
(~/AppData/Local/atom/app-1.21.2/resources/app/src/package.js:903:35)
at Package.module.exports.Package.activateNow
(~/AppData/Local/atom/app-1.21.2/resources/app/src/package.js:242:22)
at ~/AppData/Local/atom/app-1.21.2/resources/app/src/package.js:1030:34
at Function.module.exports.Emitter.simpleDispatch
(~/AppData/Local/atom/app-1.21.2/resources/app/node_modules/event-kit/lib/emitter.js:25:20)
at Emitter.module.exports.Emitter.emit
(~/AppData/Local/atom/app-1.21.2/resources/app/node_modules/event-kit/lib/emitter.js:141:34)
at PackageManager.triggerActivationHook
(~/AppData/Local/atom/app-1.21.2/resources/app/src/package-manager.js:727:40)
at Workspace.handleGrammarUsed
(~/AppData/Local/atom/app-1.21.2/resources/app/src/workspace.js:1400:40)
at TextEditor.module.exports.TextEditor.observeGrammar
(~/AppData/Local/atom/app-1.21.2/resources/app/src/text-editor.js:708:13)
at
~/AppData/Local/atom/app-1.21.2/resources/app/src/workspace.js:579:202
at ~/AppData/Local/atom/app-1.21.2/resources/app/src/workspace.js:584:19
at Function.module.exports.Emitter.simpleDispatch
(~/AppData/Local/atom/app-1.21.2/resources/app/node_modules/event-kit/lib/emitter.js:25:20)
at Emitter.module.exports.Emitter.emit
(~/AppData/Local/atom/app-1.21.2/resources/app/node_modules/event-kit/lib/emitter.js:141:34)
at PaneContainer.didAddPaneItem
(~/AppData/Local/atom/app-1.21.2/resources/app/src/pane-container.js:270:24)
```

### Commands

```
```

### Non-Core Packages

```
language-ballerina 0.8.8
```


[1] - https://github.com/ballerinalang/ballerina/tree/master/docs/grammar
[2] -
https://drive.google.com/drive/folders/1pAwP2MwZJ4IDRnY8MyAIP-zawSI9ZQoc?usp=sharing

-- 
*Thanks and Best Regards,*
Imesh Ashandimal Chandrasiri
*Software Engineer*
WSO2, Inc.
lean . enterprise . middleware
*E:* ime...@wso2.com | *P:* 0716519187


Disclaimer: This communication may contain privileged or other confidential
information and is intended exclusively for the addressee/s. If you are not
the intended recipient/s, or believe that you may have received this
communication in error, please reply to the sender indicating that fact and
delete the copy you received and in addition, you should not print, copy,
retransmit, disseminate, or otherwise use the information contained in this
communication. Internet communications cannot be guaranteed to be timely,
secure, error or virus-free. The sender does not accept liability for any
errors or omissions.
___
Dev mailing list
Dev@wso2.org
http://wso2.org/cgi-bin/mailman/listinfo/dev


Re: [Dev] Issue when running mysql db script - APIM analytics HA setup

2017-11-07 Thread Harsha Kumara
On Tue, Nov 7, 2017 at 3:18 PM, Chamalee De Silva  wrote:

> Hi Damith,
>
> mysql5.7.sql script has been added for MySQL 5.7 and later versions of
> databases.
> This is clearly described in the documentation on setting up MySQL
> documentation in [1].
>
> If we are going to add this special note, we may have to add this
> everywhere where mysql is used.
>
> @team, What is the best option ?
>
Best option would be to point to setting up database link as it contains
required information.

>
>
> [1] https://docs.wso2.com/display/AM200/Setting+up+MySQL
>
>
> On Tue, Nov 7, 2017 at 2:20 PM, Damith Wickramasinghe 
> wrote:
>
>> Hi all,
>>
>> I'm using mysql version 5.7.20. In order to populate userdb and regdb i
>> need to run mysql scripts and i have used the scripts in APIM analytics
>> pack(mysql.sql). When run below issue arises,
>>
>> ERROR 1067 (42000): Invalid default value for 'REG_CREATED_TIME'
>> ERROR 1146 (42S02): Table 'regdb.REG_RESOURCE' doesn't exist
>> ERROR 1146 (42S02): Table 'regdb.REG_RESOURCE' doesn't exist
>> ERROR 1146 (42S02): Table 'regdb.REG_RESOURCE' doesn't exist
>> ERROR 1146 (42S02): Table 'regdb.REG_RESOURCE' doesn't exist
>> ERROR 1146 (42S02): Table 'regdb.REG_RESOURCE' doesn't exist
>> ERROR 1146 (42S02): Table 'regdb.REG_RESOURCE' doesn't exist
>> ERROR 1146 (42S02): Table 'regdb.REG_RESOURCE' doesn't exist
>> ERROR 1067 (42000): Invalid default value for 'REG_LAST_UPDATED_TIME'
>> ERROR 1146 (42S02): Table 'regdb.REG_RESOURCE_HISTORY' doesn't exist
>> ERROR 1146 (42S02): Table 'regdb.REG_RESOURCE_HISTORY' doesn't exist
>> ERROR 1146 (42S02): Table 'regdb.REG_RESOURCE_HISTORY' doesn't exist
>> ERROR 1146 (42S02): Table 'regdb.REG_RESOURCE' doesn't exist
>>
>> Searching the issue found out i need to run NOT mysql.sql but
>> mysql5.7.sql. So for wt version does the mysql.sql works ? versions other
>> than  5.7 ? IF so we need to mention this clearly in the
>> docs . I found the same issue has been occurred for a customer as well.
>> I followed [1].
>>
>> [1] - https://docs.wso2.com/display/AM210/Minimum+High+Availabilit
>> y+Deployment+for+WSO2+APIM+Analytics
>>
>> Regards,
>> Damith.
>>
>> --
>> Senior Software Engineer
>> WSO2 Inc.; http://wso2.com
>> 
>> lean.enterprise.middleware
>>
>> mobile: *+94728671315 <+94%2072%20867%201315>*
>>
>> --
>> You received this message because you are subscribed to the Google Groups
>> "WSO2 Documentation Group" group.
>> To unsubscribe from this group and stop receiving emails from it, send an
>> email to documentation+unsubscr...@wso2.com.
>> For more options, visit https://groups.google.com/a/wso2.com/d/optout.
>>
>
>
>
> --
> Thanks & Regards,
>
> *Chamalee De Silva*
> Software Engineer
> *WS**O2* Inc. :http://wso2.com/
>
> Office   :- *+94 11 2145345 <%2B94%2011%202145345>*
> mobile  :- *+94 7 <%2B94%2077%202782039>1 4315942*
>
>


-- 
Harsha Kumara
Software Engineer, WSO2 Inc.
Mobile: +94775505618
Blog:harshcreationz.blogspot.com
___
Dev mailing list
Dev@wso2.org
http://wso2.org/cgi-bin/mailman/listinfo/dev


[Dev] [IAM] Clarification on usage of "Single Sign On with delegated access control"

2017-11-07 Thread Dilshani Subasinghe
Hi all,

I implemented 10th pattern "Single Sign On with delegated access control"
in this blog [1]. For that, I have followed "SAML2 Bearer Assertion Profile
for OAuth 2.0 with WSO2 Travelocity" [2] documentation.

In here we have to generate "OAuth2 Access Token" at the last step. I just
wanna clarify the use case in this. According to the pattern identified in
the blog, it uses APIM gateway to verify token. I can't identify exact
usage of token we are generating at the end of this documentation [2]. If
we are going to use IS as Key manager from APIM side, we can not follow the
exact doc. Please correct me if I misunderstood the scenario.

Any thoughts on this? Is there any way to continue with generated token
while connecting to WSO2 APIM or using any other service?

[1]
https://medium.facilelogin.com/thirty-solution-patterns-with-the-wso2-identity-server-16f9fd0c0389
[2]
https://docs.wso2.com/display/IS530/SAML2+Bearer+Assertion+Profile+for+OAuth+2.0+with+WSO2+Travelocity

Regards,
Dilshani

-- 

Dilshani Subasinghe
Software Engineer - QA *|* WSO2
lean *|* enterprise *|* middleware

Mobile : +94773375185
Blog: dilshani.me


___
Dev mailing list
Dev@wso2.org
http://wso2.org/cgi-bin/mailman/listinfo/dev


Re: [Dev] Issue when running mysql db script - APIM analytics HA setup

2017-11-07 Thread Chamalee De Silva
Hi Damith,

mysql5.7.sql script has been added for MySQL 5.7 and later versions of
databases.
This is clearly described in the documentation on setting up MySQL
documentation in [1].

If we are going to add this special note, we may have to add this
everywhere where mysql is used.

@team, What is the best option ?


[1] https://docs.wso2.com/display/AM200/Setting+up+MySQL


On Tue, Nov 7, 2017 at 2:20 PM, Damith Wickramasinghe 
wrote:

> Hi all,
>
> I'm using mysql version 5.7.20. In order to populate userdb and regdb i
> need to run mysql scripts and i have used the scripts in APIM analytics
> pack(mysql.sql). When run below issue arises,
>
> ERROR 1067 (42000): Invalid default value for 'REG_CREATED_TIME'
> ERROR 1146 (42S02): Table 'regdb.REG_RESOURCE' doesn't exist
> ERROR 1146 (42S02): Table 'regdb.REG_RESOURCE' doesn't exist
> ERROR 1146 (42S02): Table 'regdb.REG_RESOURCE' doesn't exist
> ERROR 1146 (42S02): Table 'regdb.REG_RESOURCE' doesn't exist
> ERROR 1146 (42S02): Table 'regdb.REG_RESOURCE' doesn't exist
> ERROR 1146 (42S02): Table 'regdb.REG_RESOURCE' doesn't exist
> ERROR 1146 (42S02): Table 'regdb.REG_RESOURCE' doesn't exist
> ERROR 1067 (42000): Invalid default value for 'REG_LAST_UPDATED_TIME'
> ERROR 1146 (42S02): Table 'regdb.REG_RESOURCE_HISTORY' doesn't exist
> ERROR 1146 (42S02): Table 'regdb.REG_RESOURCE_HISTORY' doesn't exist
> ERROR 1146 (42S02): Table 'regdb.REG_RESOURCE_HISTORY' doesn't exist
> ERROR 1146 (42S02): Table 'regdb.REG_RESOURCE' doesn't exist
>
> Searching the issue found out i need to run NOT mysql.sql but
> mysql5.7.sql. So for wt version does the mysql.sql works ? versions other
> than  5.7 ? IF so we need to mention this clearly in the
> docs . I found the same issue has been occurred for a customer as well.  I
> followed [1].
>
> [1] - https://docs.wso2.com/display/AM210/Minimum+High+
> Availability+Deployment+for+WSO2+APIM+Analytics
>
> Regards,
> Damith.
>
> --
> Senior Software Engineer
> WSO2 Inc.; http://wso2.com
> 
> lean.enterprise.middleware
>
> mobile: *+94728671315 <+94%2072%20867%201315>*
>
> --
> You received this message because you are subscribed to the Google Groups
> "WSO2 Documentation Group" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to documentation+unsubscr...@wso2.com.
> For more options, visit https://groups.google.com/a/wso2.com/d/optout.
>



-- 
Thanks & Regards,

*Chamalee De Silva*
Software Engineer
*WS**O2* Inc. :http://wso2.com/

Office   :- *+94 11 2145345 <%2B94%2011%202145345>*
mobile  :- *+94 7 <%2B94%2077%202782039>1 4315942*
___
Dev mailing list
Dev@wso2.org
http://wso2.org/cgi-bin/mailman/listinfo/dev


Re: [Dev] Issue when running mysql db script - APIM analytics HA setup

2017-11-07 Thread Harsha Kumara
On Tue, Nov 7, 2017 at 2:20 PM, Damith Wickramasinghe 
wrote:

> Hi all,
>
> I'm using mysql version 5.7.20. In order to populate userdb and regdb i
> need to run mysql scripts and i have used the scripts in APIM analytics
> pack(mysql.sql). When run below issue arises,
>
> ERROR 1067 (42000): Invalid default value for 'REG_CREATED_TIME'
> ERROR 1146 (42S02): Table 'regdb.REG_RESOURCE' doesn't exist
> ERROR 1146 (42S02): Table 'regdb.REG_RESOURCE' doesn't exist
> ERROR 1146 (42S02): Table 'regdb.REG_RESOURCE' doesn't exist
> ERROR 1146 (42S02): Table 'regdb.REG_RESOURCE' doesn't exist
> ERROR 1146 (42S02): Table 'regdb.REG_RESOURCE' doesn't exist
> ERROR 1146 (42S02): Table 'regdb.REG_RESOURCE' doesn't exist
> ERROR 1146 (42S02): Table 'regdb.REG_RESOURCE' doesn't exist
> ERROR 1067 (42000): Invalid default value for 'REG_LAST_UPDATED_TIME'
> ERROR 1146 (42S02): Table 'regdb.REG_RESOURCE_HISTORY' doesn't exist
> ERROR 1146 (42S02): Table 'regdb.REG_RESOURCE_HISTORY' doesn't exist
> ERROR 1146 (42S02): Table 'regdb.REG_RESOURCE_HISTORY' doesn't exist
> ERROR 1146 (42S02): Table 'regdb.REG_RESOURCE' doesn't exist
>
> Searching the issue found out i need to run NOT mysql.sql but
> mysql5.7.sql. So for wt version does the mysql.sql works ? versions other
> than  5.7 ? IF so we need to mention this clearly in the
> docs . I found the same issue has been occurred for a customer as well.  I
> followed [1].
>
mysql,sql will work versions prior to the vedrsion 5.7. We can add small
note in the page. Can you create a doc jira for that.

>
> [1] - https://docs.wso2.com/display/AM210/Minimum+High+Availabilit
> y+Deployment+for+WSO2+APIM+Analytics
>
> Regards,
> Damith.
>
> --
> Senior Software Engineer
> WSO2 Inc.; http://wso2.com
> 
> lean.enterprise.middleware
>
> mobile: *+94728671315 <+94%2072%20867%201315>*
>
>


-- 
Harsha Kumara
Software Engineer, WSO2 Inc.
Mobile: +94775505618 <+94%2077%20550%205618>
Blog:harshcreationz.blogspot.com
___
Dev mailing list
Dev@wso2.org
http://wso2.org/cgi-bin/mailman/listinfo/dev


Re: [Dev] What is the recommended way to provide Basic Auth credentials in to a soap admin service after a redirect binding login

2017-11-07 Thread Ushani Balasooriya
Hi Godwin,

Thanks for the reference. I will check where I can retrieve and set the
cookie value and call the admin service.

Regards,
Ushani

On Tue, Nov 7, 2017 at 1:51 PM, Godwin Shrimal  wrote:

> Hi Ushani,
>
> Please see my answers inline.
>
>
>>
>> Does it mean that use cookie to capture the Basic Auth token need for the
>> admin service if my understanding is correct?
>>
> You don't need to capture Basic Auth token, you can pass the cookie via
> HTTP Headers to backend, then backend validate is there exiating session
> with session id of the cookie and allow to invoke services.
>
>
>> an you please let me know what value should I retrieve from the cookie
>> and appreciate if you can guide me to an example in some documentation,
>> blog or etc.
>>
>
> You don't need to extract any value from cookie and you can pass the same
> cookie as HTTP Headers to backend. You can refer [1] how call backend APIs,
> please check the usages of that and see how to pass the required values.
>
>
> [1] https://github.com/wso2/product-is/blob/5.x.x/modules/
> jaggery-apps/user-dashboard/dashboard/controllers/wsUtil.jag
>
>
>
>>
>> Thanks,
>>
>> On Tue, Nov 7, 2017 at 12:34 PM, Godwin Shrimal  wrote:
>>
>>> Hi Ushani,
>>>
>>> According to what I explained above, you don't need to capture the
>>> username and generate the basic auth token. You can get the cookie after
>>> successful authentication and use that cookie to invoke backend services.
>>>
>>> Thanks
>>> Godwin
>>>
>>>
>>> On Tue, Nov 7, 2017 at 12:18 PM, Ushani Balasooriya 
>>> wrote:
>>>
 Hi Godwin,

 Yes that is what I need to do.
 For the Post binding I got the inputs from the servlet and set the
 Basic auth token in session and use it when invoking the backend.

 My problem is during the redirect binding.

 Since the login can be any thridparty IDP and I need to provide login
 credentials in IDP login screen, I need to find out how to capture
 credentials in order to generate Basic auth token.

 Thanks,


 On Tue, Nov 7, 2017 at 12:00 PM, Godwin Shrimal 
 wrote:

> Hi Ushani,
>
> As I understand you want to invoke services in the Identity server
> after SSO login. Please explain if not. If yes you can use same what we do
> in the identity server dashboard. We take the cookie from the header and
> use that cookie to invoke backend services.
>
>
> Thanks
> Godwin
>
> On Tue, Nov 7, 2017 at 11:20 AM, Ushani Balasooriya 
> wrote:
>
>> Hi Malithi,
>>
>> Thanks for the response. But my concern is IDP can be any one like
>> Wso2IS, Salesforce, facebook etc. So for me to invoke I assume I should
>> know the client ID and secret of the relevant IDP right? Please correct 
>> me
>> if I am wrong. I just need to invoke the admin services using Basic Auth.
>>
>> Appreciate your response.
>>
>> Thanks,
>>
>> On Tue, Nov 7, 2017 at 11:12 AM, Malithi Edirisinghe <
>> malit...@wso2.com> wrote:
>>
>>> I think you can use SAML bearer grant here and use the access token
>>> to access APIs
>>>
>>> Thanks,
>>> Malithi
>>>
>>> On Tue, Nov 7, 2017 at 10:11 AM, Ushani Balasooriya >> > wrote:
>>>
 Hi,

 Appreciate your response.

 Thanks,

 On Mon, Nov 6, 2017 at 2:04 PM, Ushani Balasooriya  wrote:

> Hi IAM team,
>
> As a part of my third party web application implementation to add
> users and roles I would like to try if the logged in admin user can 
> perform
> the relevant activity within the app.
>
> In order to test Login in to the web app I will be using SAML Post
> binding and as well as the Redirect binding.
>
> When I use the Post binding, I can capture the user name and
> password and generate Basic authentication token retrieving it from 
> the
> servlet request.
>
> My question is,
>
> 1. If I use redirect binding, since the IDP can be any application
> like wso2 IS or Facebook or salesforce etc *(a)* is it a valid
> use case to use the logged in user admin's credentials to generate 
> auth
> token?
>
> *(b)* Or should I hard code one particular admin user's
> credentials or auth token which is configured as admin for the 
> thirdparty
> web app to perform the relevant activities?
>
> 2. If *(a) *is valid, how can I retrieve it from the session. I
> can retrieve the username from the SAML2SSO session, but my question 
> is how
> to retrieve the password to generate auth token?
>
> Appreciate 

[Dev] Issue when running mysql db script - APIM analytics HA setup

2017-11-07 Thread Damith Wickramasinghe
Hi all,

I'm using mysql version 5.7.20. In order to populate userdb and regdb i
need to run mysql scripts and i have used the scripts in APIM analytics
pack(mysql.sql). When run below issue arises,

ERROR 1067 (42000): Invalid default value for 'REG_CREATED_TIME'
ERROR 1146 (42S02): Table 'regdb.REG_RESOURCE' doesn't exist
ERROR 1146 (42S02): Table 'regdb.REG_RESOURCE' doesn't exist
ERROR 1146 (42S02): Table 'regdb.REG_RESOURCE' doesn't exist
ERROR 1146 (42S02): Table 'regdb.REG_RESOURCE' doesn't exist
ERROR 1146 (42S02): Table 'regdb.REG_RESOURCE' doesn't exist
ERROR 1146 (42S02): Table 'regdb.REG_RESOURCE' doesn't exist
ERROR 1146 (42S02): Table 'regdb.REG_RESOURCE' doesn't exist
ERROR 1067 (42000): Invalid default value for 'REG_LAST_UPDATED_TIME'
ERROR 1146 (42S02): Table 'regdb.REG_RESOURCE_HISTORY' doesn't exist
ERROR 1146 (42S02): Table 'regdb.REG_RESOURCE_HISTORY' doesn't exist
ERROR 1146 (42S02): Table 'regdb.REG_RESOURCE_HISTORY' doesn't exist
ERROR 1146 (42S02): Table 'regdb.REG_RESOURCE' doesn't exist

Searching the issue found out i need to run NOT mysql.sql but mysql5.7.sql.
So for wt version does the mysql.sql works ? versions other than  5.7 ? IF
so we need to mention this clearly in the
docs . I found the same issue has been occurred for a customer as well.  I
followed [1].

[1] -
https://docs.wso2.com/display/AM210/Minimum+High+Availability+Deployment+for+WSO2+APIM+Analytics

Regards,
Damith.

-- 
Senior Software Engineer
WSO2 Inc.; http://wso2.com

lean.enterprise.middleware

mobile: *+94728671315*
___
Dev mailing list
Dev@wso2.org
http://wso2.org/cgi-bin/mailman/listinfo/dev


Re: [Dev] What is the recommended way to provide Basic Auth credentials in to a soap admin service after a redirect binding login

2017-11-07 Thread Godwin Shrimal
Hi Ushani,

Please see my answers inline.


>
> Does it mean that use cookie to capture the Basic Auth token need for the
> admin service if my understanding is correct?
>
You don't need to capture Basic Auth token, you can pass the cookie via
HTTP Headers to backend, then backend validate is there exiating session
with session id of the cookie and allow to invoke services.


> an you please let me know what value should I retrieve from the cookie and
> appreciate if you can guide me to an example in some documentation, blog or
> etc.
>

You don't need to extract any value from cookie and you can pass the same
cookie as HTTP Headers to backend. You can refer [1] how call backend APIs,
please check the usages of that and see how to pass the required values.


[1]
https://github.com/wso2/product-is/blob/5.x.x/modules/jaggery-apps/user-dashboard/dashboard/controllers/wsUtil.jag



>
> Thanks,
>
> On Tue, Nov 7, 2017 at 12:34 PM, Godwin Shrimal  wrote:
>
>> Hi Ushani,
>>
>> According to what I explained above, you don't need to capture the
>> username and generate the basic auth token. You can get the cookie after
>> successful authentication and use that cookie to invoke backend services.
>>
>> Thanks
>> Godwin
>>
>>
>> On Tue, Nov 7, 2017 at 12:18 PM, Ushani Balasooriya 
>> wrote:
>>
>>> Hi Godwin,
>>>
>>> Yes that is what I need to do.
>>> For the Post binding I got the inputs from the servlet and set the Basic
>>> auth token in session and use it when invoking the backend.
>>>
>>> My problem is during the redirect binding.
>>>
>>> Since the login can be any thridparty IDP and I need to provide login
>>> credentials in IDP login screen, I need to find out how to capture
>>> credentials in order to generate Basic auth token.
>>>
>>> Thanks,
>>>
>>>
>>> On Tue, Nov 7, 2017 at 12:00 PM, Godwin Shrimal  wrote:
>>>
 Hi Ushani,

 As I understand you want to invoke services in the Identity server
 after SSO login. Please explain if not. If yes you can use same what we do
 in the identity server dashboard. We take the cookie from the header and
 use that cookie to invoke backend services.


 Thanks
 Godwin

 On Tue, Nov 7, 2017 at 11:20 AM, Ushani Balasooriya 
 wrote:

> Hi Malithi,
>
> Thanks for the response. But my concern is IDP can be any one like
> Wso2IS, Salesforce, facebook etc. So for me to invoke I assume I should
> know the client ID and secret of the relevant IDP right? Please correct me
> if I am wrong. I just need to invoke the admin services using Basic Auth.
>
> Appreciate your response.
>
> Thanks,
>
> On Tue, Nov 7, 2017 at 11:12 AM, Malithi Edirisinghe <
> malit...@wso2.com> wrote:
>
>> I think you can use SAML bearer grant here and use the access token
>> to access APIs
>>
>> Thanks,
>> Malithi
>>
>> On Tue, Nov 7, 2017 at 10:11 AM, Ushani Balasooriya 
>> wrote:
>>
>>> Hi,
>>>
>>> Appreciate your response.
>>>
>>> Thanks,
>>>
>>> On Mon, Nov 6, 2017 at 2:04 PM, Ushani Balasooriya 
>>> wrote:
>>>
 Hi IAM team,

 As a part of my third party web application implementation to add
 users and roles I would like to try if the logged in admin user can 
 perform
 the relevant activity within the app.

 In order to test Login in to the web app I will be using SAML Post
 binding and as well as the Redirect binding.

 When I use the Post binding, I can capture the user name and
 password and generate Basic authentication token retrieving it from the
 servlet request.

 My question is,

 1. If I use redirect binding, since the IDP can be any application
 like wso2 IS or Facebook or salesforce etc *(a)* is it a valid use
 case to use the logged in user admin's credentials to generate auth 
 token?

 *(b)* Or should I hard code one particular admin user's
 credentials or auth token which is configured as admin for the 
 thirdparty
 web app to perform the relevant activities?

 2. If *(a) *is valid, how can I retrieve it from the session. I
 can retrieve the username from the SAML2SSO session, but my question 
 is how
 to retrieve the password to generate auth token?

 Appreciate your response.

 Thanks,
 --
 *Ushani Balasooriya*
 Associate Technical Lead - EE;
 WSO2 Inc; http://www.wso2.com/.
 Mobile; +94772636796


>>>
>>>
>>> --
>>> *Ushani Balasooriya*
>>> Associate Technical Lead - EE;
>>> WSO2 Inc; http://www.wso2.com/.
>>> Mobile; +94772636796
>>>
>>>
>>
>>

Re: [Dev] What is the recommended way to provide Basic Auth credentials in to a soap admin service after a redirect binding login

2017-11-07 Thread Ushani Balasooriya
Hi Godwin,

Does it mean that use cookie to capture the Basic Auth token need for the
admin service if my understanding is correct? an you please let me know
what value should I retrieve from the cookie and appreciate if you can
guide me to an example in some documentation, blog or etc.

Thanks,

On Tue, Nov 7, 2017 at 12:34 PM, Godwin Shrimal  wrote:

> Hi Ushani,
>
> According to what I explained above, you don't need to capture the
> username and generate the basic auth token. You can get the cookie after
> successful authentication and use that cookie to invoke backend services.
>
> Thanks
> Godwin
>
>
> On Tue, Nov 7, 2017 at 12:18 PM, Ushani Balasooriya 
> wrote:
>
>> Hi Godwin,
>>
>> Yes that is what I need to do.
>> For the Post binding I got the inputs from the servlet and set the Basic
>> auth token in session and use it when invoking the backend.
>>
>> My problem is during the redirect binding.
>>
>> Since the login can be any thridparty IDP and I need to provide login
>> credentials in IDP login screen, I need to find out how to capture
>> credentials in order to generate Basic auth token.
>>
>> Thanks,
>>
>>
>> On Tue, Nov 7, 2017 at 12:00 PM, Godwin Shrimal  wrote:
>>
>>> Hi Ushani,
>>>
>>> As I understand you want to invoke services in the Identity server after
>>> SSO login. Please explain if not. If yes you can use same what we do in the
>>> identity server dashboard. We take the cookie from the header and use that
>>> cookie to invoke backend services.
>>>
>>>
>>> Thanks
>>> Godwin
>>>
>>> On Tue, Nov 7, 2017 at 11:20 AM, Ushani Balasooriya 
>>> wrote:
>>>
 Hi Malithi,

 Thanks for the response. But my concern is IDP can be any one like
 Wso2IS, Salesforce, facebook etc. So for me to invoke I assume I should
 know the client ID and secret of the relevant IDP right? Please correct me
 if I am wrong. I just need to invoke the admin services using Basic Auth.

 Appreciate your response.

 Thanks,

 On Tue, Nov 7, 2017 at 11:12 AM, Malithi Edirisinghe  wrote:

> I think you can use SAML bearer grant here and use the access token to
> access APIs
>
> Thanks,
> Malithi
>
> On Tue, Nov 7, 2017 at 10:11 AM, Ushani Balasooriya 
> wrote:
>
>> Hi,
>>
>> Appreciate your response.
>>
>> Thanks,
>>
>> On Mon, Nov 6, 2017 at 2:04 PM, Ushani Balasooriya 
>> wrote:
>>
>>> Hi IAM team,
>>>
>>> As a part of my third party web application implementation to add
>>> users and roles I would like to try if the logged in admin user can 
>>> perform
>>> the relevant activity within the app.
>>>
>>> In order to test Login in to the web app I will be using SAML Post
>>> binding and as well as the Redirect binding.
>>>
>>> When I use the Post binding, I can capture the user name and
>>> password and generate Basic authentication token retrieving it from the
>>> servlet request.
>>>
>>> My question is,
>>>
>>> 1. If I use redirect binding, since the IDP can be any application
>>> like wso2 IS or Facebook or salesforce etc *(a)* is it a valid use
>>> case to use the logged in user admin's credentials to generate auth 
>>> token?
>>>
>>> *(b)* Or should I hard code one particular admin user's credentials
>>> or auth token which is configured as admin for the thirdparty web app to
>>> perform the relevant activities?
>>>
>>> 2. If *(a) *is valid, how can I retrieve it from the session. I can
>>> retrieve the username from the SAML2SSO session, but my question is how 
>>> to
>>> retrieve the password to generate auth token?
>>>
>>> Appreciate your response.
>>>
>>> Thanks,
>>> --
>>> *Ushani Balasooriya*
>>> Associate Technical Lead - EE;
>>> WSO2 Inc; http://www.wso2.com/.
>>> Mobile; +94772636796
>>>
>>>
>>
>>
>> --
>> *Ushani Balasooriya*
>> Associate Technical Lead - EE;
>> WSO2 Inc; http://www.wso2.com/.
>> Mobile; +94772636796
>>
>>
>
>
> --
>
> *Malithi Edirisinghe*
> Associate Technical Lead
> WSO2 Inc.
>
> Mobile : +94 (0) 718176807
> malit...@wso2.com
>



 --
 *Ushani Balasooriya*
 Associate Technical Lead - EE;
 WSO2 Inc; http://www.wso2.com/.
 Mobile; +94772636796


>>>
>>>
>>> --
>>> *Godwin Amila Shrimal*
>>> Associate Technical Lead
>>> WSO2 Inc.; http://wso2.com
>>> lean.enterprise.middleware
>>>
>>> mobile: *+94772264165*
>>> linkedin: *https://www.linkedin.com/in/godwin-amila-2ba26844/
>>> *
>>> twitter: https://twitter.com/godwinamila
>>> 
>>>
>>
>>
>>
>> --
>> *Ushani Balasooriya*
>> Associate