WSO2 APIM : adding SSL certificate for APIs endpoint using rest service - wso2-api-manager

I am trying to add SSL certificates for the endpoint of the APIs which are created in the APIM 2.5.0
I am able to add the SSL certificate using keyimport tool from commandline and things are working as expected.
But, is there a possibility to add the certificate using restAPI when we are adding the APIs using restAPIs.
May be in the payload which is generated to add an API in the APIM as stated in the link https://docs.wso2.com/display/AM250/RESTful+APIs
Thanks

WSO2 API Manager has a dynamic SSL certificate installation feature where you can skip manual importing the certificate for the endpoint. This feature is only available in APIM 2.5.0 WUM updated pack and GA pack of APIM 2.6.0. https://docs.wso2.com/display/AM250/Dynamic+SSL+Certificate+Installation
In APIM 2.6.0, this feature is enhanced by introducing a REST API for importing certificates. For your endpoints, you can import a certificate. https://docs.wso2.com/display/AM260/apidocs/publisher/#!/operations#CertificatesIndividual#certificatesPost
If you want to use the REST API for importing certs, you have to go with APIM 2.6.0.

Related

Can I use the token info endpoint instead of the official Google Client SDK (in production)?

I am currently implementing Google authentication on my client's website (back in Symfony), and would like to install the Google SDK on its API (https://developers.google.com/identity/sign-in/web/backend-auth). The situation is such that we can't install this SDK for the moment (deep dependency conflict).
Could we use (temporarily) tokeninfo api endpoint instead of the Google PHP SDK recommended by Google for production ?

WSO2 API Header is not working as expected

I have created API in wso2 API manager and specified header as a required field but when API was hit by using postman I am able to get the response. Do I need to enable header check in any configuration file Please let me know.
I checked WSO2 2.6.0 API documents but did not find solution.

WSO2 analytic vs. IS analytic

Does anyone know difference between API analytics and IS analytics component?
Why those are separated components?
Or does someone accomplished to gather them?
Also it is possible to export dashboard but what to do with it when I am not able to import it.
APIM Analytics comes with WSO2 API Manager. IS Analytics comes with WSO2 Identity Server. Both analytics solutions are built on top of WSO2 Data Analytics Server. If we take IS Analytics it will provide useful stats and analytics based on the events published through WSO2 Identity Server such as login events, session related data etc. It's the same with APIM analytics.
If you are using both WSO2 APIM and WSO2 IS you can install both analytics features on top of WSO2 DAS. You can refer the WSO2 Documentation for more details.

ServiceDataPublisherAdmin not set in wso2 api manager gateway

I am setting up wso2 API manager 1.10.x with DAS 3.0.1 for publishing API statistics using mysql. My API manager system is clustered with gateway worker node on a separate VM. I followed the documents to enable analytics for API manager via UI. I also followed this document to manually enable analytics for gateway worker node. http://blog.rukspot.com/2016/05/configure-wso2-apim-analytics-using-xml.html After setup, I restart all servers, everything seems fine. But when I make a request to published API, gateway does not publish any statistics to DAS receiver. No data in DAS summary tables either.
By debugging wso2 Gateway, I am able to narrow it down to the fact that
private static ServiceDataPublisherAdmin dataPublisherAdminService; inside org.wso2.carbon.apimgt.impl.internal.APIManagerComponent never get set. Therefore APIMgtUsageHandler does not do anything.
Any idea on what could cause this to happen?
Thanks.
Figured it out myself.
bundle org.wso2.carbon.statistics_4.4.8 and 2 other statistics bundles are necessary for gateway worker to publish statistics data to DAS. But worker profile provided in the package of wso2 API manager 1.10.0 had them excluded.
To work around it, start wso2 on worker node with -Dprofile=default.
You can use osgi console to confirm the activation of these bundles. Once the bundle is activated, class inside is instantiated, gateway will start to publish statistics to DAS when you invoke a published API.

How to protect REST API with wso2 IS?

I now have a NodeJS REST API. It is CRUD service.
Does anyone know how to secure/protect my APIs step by step with wso2 OAuth2?
If you simply want to protect your REST API with OAuth2 use the WSO2 API Manager.
You can follow the quick start guide to get started.
Details related to adding your API and enabling OAuth2 protection is mentioned here in the quick start guide.

Resources