wso2 apim SOAP endpoint with username and password - web-services

I have wso2 apim 2.1 and I have request to connect to SOAP endpoint which is secured with username and password.
During add procedure of SOAP endpoint I dont have possibility to enter such credentials nor possiblity to use mediation(eg like for rest api) as I get not authorized before enetring next phase. is there a way how to do this without using ESB ?
how to connect to secured SOAP backend using just apim ?
or Do I have to use ESB and follow similar way as LINK
thank you for any advice

We were not able to parse the backend wsdl from some reason and we have done workaround by donwloading wsdl and manualy pushing it to registry, after that we were able to follow next steps.

Related

How do I create a Custom Client Authenticator in WSO2 Identity Server

I am trying to set up a custom client authenticator in WSO2 Identity Server, I would like to retrieve an access token with client_credentials specifying a specific scope and have a jwt token returned with custom claims inserted. I've tried writing my own Client Authenticator but I'm having some trouble getting the OSGi bundle to pick up correctly during WSO2 startup and all other attempts at customizing the auth flow have failed.
Is there anyone who would be able to point me in the right direction as to where I might find useful information on how to achieve what I'm trying to achieve? TIA.
Using WSO2 Identity Server, you are able to extend the client authentication implementation. You can write your own client authentication mechanism following a specification or any other standard.
Please follow the below doc link to create the custom client Authenticator:
https://is.docs.wso2.com/en/latest/learn/writing-a-new-oauth-client-authenticator/

Consume wsdl using wso2

I have one wsdl which is working fine on mule esb.
Now i am new to wso2 i need to consume that wsdl via wso2.
I have tried to consume it from Wso2 developer studio but it showed 202 http status
Anyone can help me in this
The request of service is in xml with header APIKEY and username password basic authentication.
Anybody can help me in this problem.
I Chris, I am going to describe all the necessary steps to achieve what you want.
Create an WSDL Endpoint
Create a proxy, can be Custom Proxy.
2.1 So, depending on what you want to do (get/post/...).
For GET instance: You can Send the endpoint in (inSequence) and consume the response in outSequence with Payload factory ( https://docs.wso2.com/display/ESB500/PayloadFactory+Mediator ) passing the necessary arguments.
Just wsdl endpoint whit proper configuration.

WSO2 Identity Server Authorization Service

I am new to WSO2 Identity Server(4.6). I have a use case, where I have a rest service on ESB (WSO2 ESB 4.9). And I would like to give resource level access to various users.
I thought of using WSO2 identity server for authorizing the user and using the token for accessing the rest service. I was going through the playground example, but that is not something I would like to do, where the Authorize service opens the Identity Server Authorization Service. It seems to be sequential, and assumes that the user/resource owner are the same.
I would like to do all that programatically, and just give the aothorization code to the user, and let him call the token service to get the token. Is this possible?
Thank you
You can use the https://localhost:8243/token endpoint for your use case. You can refer to below links for more information
https://docs.wso2.com/display/IS500/OAuth+Token+Revocation+with+WSO2+Identity+Server
https://docs.wso2.com/display/AM190/Token+API

Does WSO 2 API Manager prevent to XSS and CRSF security error

I'm researching WSO2 API Manager and I discover that if I use WSO2 API Publisher and API Store, I would meet XSS and CSRF security errors. With XSS, I see that WSO2 didn't encode HTML character input. With CSRF, I see that WSO2 didn't create token when I request from client to server and vise versa.
Does everyone know how to config WSO2 to prevent these security error or how to fix them.
Thanks in advanced.
On our side, there are a few things we do when publishing/consuming APIs via the API Publisher and API Store:
Set the Transports property to just HTTPS so that we can limit API availability to just HTTPS.
For each HTTP method, we set the Auth Type to either Application, Application User or both, but never none. This will force the client to utilize the WSO2 Access Token scheme to invoke the APIs hosted on the API Store.
On the client side, we have been invoking the Token API to generate and renew user and application access token so that we don't have to manually re-generate keys in the API Store.
Utilize API in-sequence to escape special characters.
We fix these type of security issues in our next release AM V 1.7.1. You can expect it in 3rd week of September.

WSO2 Identity Server obtain SAML token for rest call

I have the two applications that both support SAML2 SSO using WSO2 Identity Server. During application bootstrap (when still no user request is processed) i need one of the applications to get information from the other using REST call. However this REST call should provide a SAML token for security purposes. I need a way to remotely get SAML2 token and use it for REST calls. I have read a post about rest sts client without esb however i can't find a sample code on how to get a SAML token for my REST calls. What is the way to obtain such SAML token? Is there sample source code?
You can follow this blog [1] get passive STS sample. But if you are using WSO2 Identity server 5.0 user interface bit different than in this blog.
[1] http://dulanja.blogspot.com/2013/09/passive-sts-java-sample-with-wso2.html