<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>question Re: How to authenticate when LDAP is configured to get ACCESS tocken to execute NIFI REST Client calls? in Archives of Support Questions (Read Only)</title>
    <link>https://community.cloudera.com/t5/Archives-of-Support-Questions/How-to-authenticate-when-LDAP-is-configured-to-get-ACCESS/m-p/121859#M55347</link>
    <description>&lt;P&gt;Yes, because we are using a generic application user id and we would have it encrypted in a property file.&lt;/P&gt;</description>
    <pubDate>Tue, 28 Feb 2017 17:09:49 GMT</pubDate>
    <dc:creator>ramkrish9198</dc:creator>
    <dc:date>2017-02-28T17:09:49Z</dc:date>
    <item>
      <title>How to authenticate when LDAP is configured to get ACCESS tocken to execute NIFI REST Client calls?</title>
      <link>https://community.cloudera.com/t5/Archives-of-Support-Questions/How-to-authenticate-when-LDAP-is-configured-to-get-ACCESS/m-p/121855#M55343</link>
      <description>&lt;P&gt;After LDAP configuration, if i execute a curl command and make NIFI REST Client call:&lt;/P&gt;&lt;P&gt;"curl -i -k -X GET https://URL/nifi-api/flow/process-groups/16fc1e19-12ed-133d-079e-613116e15383" i get the error:&lt;/P&gt;&lt;P&gt;"Unable to perform the desired action due to insufficient permissions. Contact the system administrator.".&lt;/P&gt;&lt;P&gt;Which means i need to use one of the options mentioned in /nifi-api/access/ - to authenticate and then perform the above curl command to succeed. The REST calls against /nifi-api/access works meaning:&lt;/P&gt;&lt;P&gt;"curl -i -k -X GET https://URL/nifi-api/access" returns:&lt;/P&gt;&lt;P&gt;"{"accessStatus":{"status":"UNKNOWN","message":"No credentials supplied, unknown user."}}"&lt;/P&gt;</description>
      <pubDate>Thu, 23 Feb 2017 21:07:24 GMT</pubDate>
      <guid>https://community.cloudera.com/t5/Archives-of-Support-Questions/How-to-authenticate-when-LDAP-is-configured-to-get-ACCESS/m-p/121855#M55343</guid>
      <dc:creator>ramkrish9198</dc:creator>
      <dc:date>2017-02-23T21:07:24Z</dc:date>
    </item>
    <item>
      <title>Re: How to authenticate when LDAP is configured to get ACCESS tocken to execute NIFI REST Client calls?</title>
      <link>https://community.cloudera.com/t5/Archives-of-Support-Questions/How-to-authenticate-when-LDAP-is-configured-to-get-ACCESS/m-p/121856#M55344</link>
      <description>&lt;P&gt;&lt;A rel="user" href="https://community.cloudera.com/users/15048/ramkrish9198.html" nodeid="15048"&gt;@Ramakrishnan V&lt;/A&gt;&lt;/P&gt;&lt;P&gt;You will need to use the following curl command to obtain a token for your LDAP user:

&lt;/P&gt;&lt;PRE&gt;curl 'https://&amp;lt;hostname&amp;gt;:&amp;lt;port&amp;gt;/nifi-api/access/token' -H 'Content-Type: application/x-www-form-urlencoded; charset=UTF-8' --data 'username=admin&amp;amp;password=admin' --compressed --insecure&lt;/PRE&gt;&lt;P&gt;Once you have your token you will need to pass that token as the bearer of all subsequent curl command you execute against the NiFi api by adding teh following to your curl commads:&lt;/P&gt;&lt;PRE&gt;-H 'Authorization: Bearer eyJhbGciOiJIUzI1NiJ9.eyJzdWIiOiJjbj1hZG1pbixkYz1leGFtcGxlLGRjPW9yZyIsImlzcyI6IkxkYXBQcm92aWRlciIsIm
F1ZCI6IkxkYXBQcm92aWRlciIsInByZWZlcnJlZF91c2VybmFtZSI6ImFkbWluIiwia2lkIjoxLCJleHAiOjE0ODcxNDM2OTEs
ImlhdCI6MTQ4NzEwMDQ5MX0.GwwJ0Yz4_KXUAMNIH500jw8YcIk3e6ZdcT3LCrrkHjc'&lt;/PRE&gt;&lt;P&gt;The odd string above is an example of the token you will get back from the first command.&lt;/P&gt;&lt;P&gt;Thanks,&lt;/P&gt;&lt;P&gt;Matt&lt;/P&gt;</description>
      <pubDate>Thu, 23 Feb 2017 21:12:47 GMT</pubDate>
      <guid>https://community.cloudera.com/t5/Archives-of-Support-Questions/How-to-authenticate-when-LDAP-is-configured-to-get-ACCESS/m-p/121856#M55344</guid>
      <dc:creator>MattWho</dc:creator>
      <dc:date>2017-02-23T21:12:47Z</dc:date>
    </item>
    <item>
      <title>Re: How to authenticate when LDAP is configured to get ACCESS tocken to execute NIFI REST Client calls?</title>
      <link>https://community.cloudera.com/t5/Archives-of-Support-Questions/How-to-authenticate-when-LDAP-is-configured-to-get-ACCESS/m-p/121857#M55345</link>
      <description>&lt;P&gt;Thanks Matt, so in case if am using an Apache HTTP client package and executing the above rest calls within in a executable jar file, then i would need need to do decryption of encrypted password and hit it in the way above...&lt;/P&gt;</description>
      <pubDate>Thu, 23 Feb 2017 22:38:44 GMT</pubDate>
      <guid>https://community.cloudera.com/t5/Archives-of-Support-Questions/How-to-authenticate-when-LDAP-is-configured-to-get-ACCESS/m-p/121857#M55345</guid>
      <dc:creator>ramkrish9198</dc:creator>
      <dc:date>2017-02-23T22:38:44Z</dc:date>
    </item>
    <item>
      <title>Re: How to authenticate when LDAP is configured to get ACCESS tocken to execute NIFI REST Client calls?</title>
      <link>https://community.cloudera.com/t5/Archives-of-Support-Questions/How-to-authenticate-when-LDAP-is-configured-to-get-ACCESS/m-p/121858#M55346</link>
      <description>&lt;P&gt;&lt;A rel="user" href="https://community.cloudera.com/users/15048/ramkrish9198.html" nodeid="15048"&gt;@Ramakrishnan V&lt;/A&gt; Just to clarify, is the password in your code encrypted? If so then yes, you would need to decrypt the password being sent in the request to /nifi-api/access/token. NiFi only supports username/password login's over HTTPS so that communication will be secure.&lt;/P&gt;</description>
      <pubDate>Fri, 24 Feb 2017 01:28:19 GMT</pubDate>
      <guid>https://community.cloudera.com/t5/Archives-of-Support-Questions/How-to-authenticate-when-LDAP-is-configured-to-get-ACCESS/m-p/121858#M55346</guid>
      <dc:creator>mgilman</dc:creator>
      <dc:date>2017-02-24T01:28:19Z</dc:date>
    </item>
    <item>
      <title>Re: How to authenticate when LDAP is configured to get ACCESS tocken to execute NIFI REST Client calls?</title>
      <link>https://community.cloudera.com/t5/Archives-of-Support-Questions/How-to-authenticate-when-LDAP-is-configured-to-get-ACCESS/m-p/121859#M55347</link>
      <description>&lt;P&gt;Yes, because we are using a generic application user id and we would have it encrypted in a property file.&lt;/P&gt;</description>
      <pubDate>Tue, 28 Feb 2017 17:09:49 GMT</pubDate>
      <guid>https://community.cloudera.com/t5/Archives-of-Support-Questions/How-to-authenticate-when-LDAP-is-configured-to-get-ACCESS/m-p/121859#M55347</guid>
      <dc:creator>ramkrish9198</dc:creator>
      <dc:date>2017-02-28T17:09:49Z</dc:date>
    </item>
  </channel>
</rss>

