문제

I have to use nginx as proxy for an API manager installation using secure SSL connection. Any hint on how to configure all to make it work?

Thanks

Luca

도움이 되었습니까?

해결책

Current version of API manager doesnt support "https" endpoints...We have that in our roadmap and will fix that in future release. But you can use ESB between APIManager and your backend service to route the request

다른 팁

As of WSO2 API Manager version 1.3.0, support for invoking secured back-end services has been added. Please see below synapse configuration of a sample API which invokes a secured back-end service. Currently support is only available for services secured over Basic Auth.

<api xmlns="http://ws.apache.org/ns/synapse" name="admin--SecuredAPI" context="/secure" version="1.0.0" version-type="url"> 
    <resource methods="POST GET OPTIONS DELETE PUT" url-mapping="/*"> 
        <inSequence> 
            <property name="Authorization" expression="fn:concat('Basic ', base64Encode('username:password'))" scope="transport"/> 
            <property name="POST_TO_URI" value="true" scope="axis2"/> 
            <filter source="$ctx:AM_KEY_TYPE" regex="PRODUCTION"> 
                <then> 
                    <send> 
                        <endpoint name="admin--SecuredAPI_APIEndpoint_0"> 
                            <address uri="https://securebackend.com/search"> 
                                <timeout> 
                                    <duration>30000</duration> 
                                    <responseAction>fault</responseAction> 
                                </timeout> 
                                <suspendOnFailure> 
                                    <errorCodes>-1</errorCodes> 
                                    <initialDuration>0</initialDuration> 
                                    <progressionFactor>1.0</progressionFactor> 
                                    <maximumDuration>0</maximumDuration> 
                                </suspendOnFailure> 
                                <markForSuspension> 
                                    <errorCodes>-1</errorCodes> 
                                </markForSuspension> 
                            </address> 
                        </endpoint> 
                    </send> 
                </then> 
                <else> 
                    <sequence key="_sandbox_key_error_"/> 
                </else> 
            </filter> 
        </inSequence> 
        <outSequence> 
            <send/> 
        </outSequence> 
    </resource> 
    <handlers> 
        <handler class="org.wso2.carbon.apimgt.gateway.handlers.security.APIAuthenticationHandler"/> 
        <handler class="org.wso2.carbon.apimgt.usage.publisher.APIMgtUsageHandler"/> 
        <handler class="org.wso2.carbon.apimgt.usage.publisher.APIMgtGoogleAnalyticsTrackingHandler"/> 
        <handler class="org.wso2.carbon.apimgt.gateway.handlers.throttling.APIThrottleHandler"> 
            <property name="id" value="A"/> 
            <property name="policyKey" value="gov:/apimgt/applicationdata/tiers.xml"/> 
        </handler> 
        <handler class="org.wso2.carbon.apimgt.gateway.handlers.ext.APIManagerExtensionHandler"/> 
    </handlers> 
</api> 

Thanks, Nuwan.

라이센스 : CC-BY-SA ~와 함께 속성
제휴하지 않습니다 StackOverflow
scroll top