Warning: file_get_contents(/data/phpspider/zhask/data//catemap/5/bash/15.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
Curl 使用ldap凭据进行认证_Curl_Ldap_Servicenow Rest Api - Fatal编程技术网

Curl 使用ldap凭据进行认证

Curl 使用ldap凭据进行认证,curl,ldap,servicenow-rest-api,Curl,Ldap,Servicenow Rest Api,我正在尝试使用使用ldap身份验证的curl连接到servicenow服务器 我的命令: curl -ntlm -u user https://my.service-now.com/api/now/table/incident 然后我得到: Enter host password for user 'user': {"error":{"message":"User Not Authenticated","detail":"Required to provide Auth information

我正在尝试使用使用ldap身份验证的curl连接到servicenow服务器

我的命令:

curl -ntlm -u user https://my.service-now.com/api/now/table/incident
然后我得到:

Enter host password for user 'user':
{"error":{"message":"User Not Authenticated","detail":"Required to provide Auth information"},"status":"failure"}

如何通过curl命令获取身份验证?

您可以尝试此获取身份验证

curl-ntlm”https://my.service-now.com/api/now/table/incident" \

--用户'user':'user_password'
尝试使用附加标志运行示例:--header>curl-ntlm”“--user'user':'pass'--header“Accept:application/json”{“error”:{“message”:“user Not Authenticated”,“detail”:“Required to provide Auth information”},“status”:“failure”}但是仍然会收到相同的错误您是否通过登录实例来检查user和pass在服务中是否有效。在这里尝试一下你是对的-我不能从my.service-now.com/login.do地址登录,但我可以登录,应该可以从login.do访问API。您需要为您的ID设置后端密码,然后重试。只有SN管理员可以从用户配置文件执行此操作