Edge for Private Cloud v. 4.17.09
Edge पर एसएएमएल चालू करने के बाद, बेसिक ऑथ को बंद किया जा सकता है. हालांकि, बेसिक ऑथेंटिकेशन को बंद करने से पहले:
- पक्का करें कि आपने सिस्टम एडमिन के साथ-साथ Edge के सभी उपयोगकर्ताओं को अपने एसएएमएल आईडीपी में जोड़ लिया हो.
- पक्का करें कि आपने Edge यूज़र इंटरफ़ेस (यूआई) और Edge मैनेजमेंट एपीआई पर, एसएएमएल ऑथेंटिकेशन की अच्छी तरह से जांच कर ली हो.
- अगर एपीआई BaaS का भी इस्तेमाल किया जा रहा है, तो एपीआई BaaS पर एसएएमएल को कॉन्फ़िगर करें और उसकी जांच करें. एपीआई BaaS के लिए एसएएमएल चालू करना देखें.
- अगर डेवलपर सेवाओं के पोर्टल का इस्तेमाल किया जा रहा है, तो पोर्टल पर एसएएमएल को कॉन्फ़िगर करें और उसकी जांच करें. इससे यह पक्का किया जा सकेगा कि पोर्टल, Edge से कनेक्ट हो सकता है. Edge के साथ कम्यूनिकेट करने के लिए, एसएएमएल का इस्तेमाल करने के लिए डेवलपर सेवाओं के पोर्टल को कॉन्फ़िगर करना देखें.
मौजूदा सुरक्षा प्रोफ़ाइल देखना
Edge की सुरक्षा प्रोफ़ाइल देखकर, मौजूदा कॉन्फ़िगरेशन का पता लगाया जा सकता है. इससे यह पता चलता है कि बेसिक ऑथेंटिकेशन और एसएएमएल की सुविधा चालू है या नहीं. Edge में इस्तेमाल की जा रही मौजूदा सुरक्षा प्रोफ़ाइल देखने के लिए, Edge मैनेजमेंट सर्वर पर Edge मैनेजमेंट एपीआई कॉल का इस्तेमाल करें:
> curl -H "accept:application/xml" http://localhost:8080/v1/securityprofile -u sysAdminEmail:pWordअगर आपने अब तक एसएएमएल को कॉन्फ़िगर नहीं किया है, तो आपको यहां दिखाया गया जवाब मिलेगा. इसका मतलब है कि बेसिक ऑथेंटिकेशन की सुविधा चालू है:
<SecurityProfile enabled="true" name="securityprofile">
<UserAccessControl enabled="true">
</UserAccessControl>
</SecurityProfile>अगर आपने पहले से ही SAML को चालू किया हुआ है, तो आपको आउटपुट में <ssoserver> टैग दिखेगा:
<SecurityProfile enabled="true" name="securityprofile">
<UserAccessControl enabled="true">
<SSOServer>
<BasicAuthEnabled>true</BasicAuthEnabled>
<PublicKeyEndPoint>/token_key</PublicKeyEndPoint>
<ServerUrl>http://35.197.37.220:9099</ServerUrl>
</SSOServer>
</UserAccessControl>
</SecurityProfile>ध्यान दें कि एसएएमएल की सुविधा वाले वर्शन में, <BasicAuthEnabled>true</BasicAuthEnabled> भी दिखता है. इसका मतलब है कि बेसिक ऑथेंटिकेशन की सुविधा अब भी चालू है.
बुनियादी पुष्टि करने की सुविधा बंद करें
बेसिक ऑथेंटिकेशन की सुविधा बंद करने के लिए, Edge मैनेजमेंट सर्वर पर Edge मैनेजमेंट एपीआई कॉल का इस्तेमाल करें. ध्यान दें कि आपको पेलोड के तौर पर, पिछले सेक्शन में दिखाए गए एक्सएमएल ऑब्जेक्ट को पास करना होगा. सिर्फ़ एक अंतर है कि आपको <BasicAuthEnabled>false</BasicAuthEnabled> सेट करना होगा:
> curl -H "Content-Type: application/xml"
http://localhost:8080/v1/securityprofile -u sysAdminEmail:pWord -d
'<SecurityProfile enabled="true" name="securityprofile">
<UserAccessControl enabled="true">
<SSOServer>
<BasicAuthEnabled>false</BasicAuthEnabled>
<PublicKeyEndPoint>/token_key</PublicKeyEndPoint>
<ServerUrl>http://35.197.37.220:9099</ServerUrl>
</SSOServer>
</UserAccessControl>
</SecurityProfile>'बेसिक ऑथ को बंद करने के बाद, Edge मैनेजमेंट एपीआई का कोई भी ऐसा कॉल जो बेसिक ऑथ क्रेडेंशियल पास करता है, यह गड़बड़ी दिखाता है:
<Error>
<Code>security.SecurityProfileBasicAuthDisabled</Code>
<Message>Basic Authentication scheme not allowed</Message>
<Contexts/>
</Error>बुनियादी पुष्टि करने की सुविधा को फिर से चालू करना
अगर आपको किसी वजह से बेसिक ऑथेंटिकेशन को फिर से चालू करना है, तो यह तरीका अपनाएं:
चेतावनी: पुष्टि करने के बुनियादी तरीके को फिर से चालू करने के लिए, आपको Edge पर पुष्टि करने के सभी तरीकों को कुछ समय के लिए बंद करना होगा. इनमें एसएएमएल भी शामिल है.
- किसी भी Edge ZooKeeper नोड में लॉग इन करें.
- सभी सुरक्षा सुविधाएं बंद करने के लिए, यह बैश स्क्रिप्ट चलाएं:
चेतावनी: यह तरीका, Edge पर पुष्टि करने की सभी सुविधाएं बंद कर देता है. इनमें एसएएमएल भी शामिल है.
#! /bin/bash
/opt/apigee/apigee-zookeeper/bin/zkCli.sh -server localhost:2181 <<EOFset /system/securityprofile <SecurityProfile></SecurityProfile>quitEOF
आपको इस तरह का आउटपुट दिखेगा:
Connecting to localhost:2181
Welcome to ZooKeeper!
JLine की सुविधा चालू है
WATCHER::
WatchedEvent state:SyncConnected type:None path:null[zk: localhost:2181(CONNECTED) 0] set /system/securityprofile <SecurityProfile></SecurityProfile>cZxid = 0x89...
[zk: localhost:2181(CONNECTED) 1] quit
Quitting… - बेसिक ऑथ और एसएएमएल ऑथेंटिकेशन को फिर से चालू करें:
> curl -H "Content-Type: application/xml"
अब बेसिक ऑथेंटिकेशन का इस्तेमाल फिर से किया जा सकता है.
http://localhost:8080/v1/securityprofile -u sysAdminEmail:pWord -d
'<SecurityProfile enabled="true" name="securityprofile">
<UserAccessControl enabled="true">
<SSOServer>
<BasicAuthEnabled>true</BasicAuthEnabled>
<PublicKeyEndPoint>/token_key</PublicKeyEndPoint>
<ServerUrl>http://35.197.37.220:9099</ServerUrl>
</SSOServer>
</UserAccessControl>
</SecurityProfile>'