How to debug curl access denied?












0














I am using curl to search artifacts from Artifactory, like this:



curl -s -u user:passwd http://artifactory:8081/artifactory/api/search/gavc?a=8710&v=REL-0041-20181219.003944-userdebug&c=fastboot | /usr/bin/jq -r .results.uri


But it shows access denied error



[1] 25600
[2] 25601
[2]+ Done v=REL-0041-20181119.003944-userdebug
Access denied


access denied



I have no idea how to debug this problem, give me some idea please.



curl version: 7.47.0










share|improve this question






















  • try curl -s -u user:passwd "http://artifactory:8081/artifactory/api/search/gavc?a=8710&v=REL-0041-20181219.003944-userdebug&c=fastboot" first, your command is not correctly escaped
    – Alvin Liang
    Dec 19 at 2:27










  • Still access denied.
    – Kuanlin Chen
    Dec 19 at 2:31
















0














I am using curl to search artifacts from Artifactory, like this:



curl -s -u user:passwd http://artifactory:8081/artifactory/api/search/gavc?a=8710&v=REL-0041-20181219.003944-userdebug&c=fastboot | /usr/bin/jq -r .results.uri


But it shows access denied error



[1] 25600
[2] 25601
[2]+ Done v=REL-0041-20181119.003944-userdebug
Access denied


access denied



I have no idea how to debug this problem, give me some idea please.



curl version: 7.47.0










share|improve this question






















  • try curl -s -u user:passwd "http://artifactory:8081/artifactory/api/search/gavc?a=8710&v=REL-0041-20181219.003944-userdebug&c=fastboot" first, your command is not correctly escaped
    – Alvin Liang
    Dec 19 at 2:27










  • Still access denied.
    – Kuanlin Chen
    Dec 19 at 2:31














0












0








0







I am using curl to search artifacts from Artifactory, like this:



curl -s -u user:passwd http://artifactory:8081/artifactory/api/search/gavc?a=8710&v=REL-0041-20181219.003944-userdebug&c=fastboot | /usr/bin/jq -r .results.uri


But it shows access denied error



[1] 25600
[2] 25601
[2]+ Done v=REL-0041-20181119.003944-userdebug
Access denied


access denied



I have no idea how to debug this problem, give me some idea please.



curl version: 7.47.0










share|improve this question













I am using curl to search artifacts from Artifactory, like this:



curl -s -u user:passwd http://artifactory:8081/artifactory/api/search/gavc?a=8710&v=REL-0041-20181219.003944-userdebug&c=fastboot | /usr/bin/jq -r .results.uri


But it shows access denied error



[1] 25600
[2] 25601
[2]+ Done v=REL-0041-20181119.003944-userdebug
Access denied


access denied



I have no idea how to debug this problem, give me some idea please.



curl version: 7.47.0







curl






share|improve this question













share|improve this question











share|improve this question




share|improve this question










asked Dec 19 at 2:15









Kuanlin Chen

53




53












  • try curl -s -u user:passwd "http://artifactory:8081/artifactory/api/search/gavc?a=8710&v=REL-0041-20181219.003944-userdebug&c=fastboot" first, your command is not correctly escaped
    – Alvin Liang
    Dec 19 at 2:27










  • Still access denied.
    – Kuanlin Chen
    Dec 19 at 2:31


















  • try curl -s -u user:passwd "http://artifactory:8081/artifactory/api/search/gavc?a=8710&v=REL-0041-20181219.003944-userdebug&c=fastboot" first, your command is not correctly escaped
    – Alvin Liang
    Dec 19 at 2:27










  • Still access denied.
    – Kuanlin Chen
    Dec 19 at 2:31
















try curl -s -u user:passwd "http://artifactory:8081/artifactory/api/search/gavc?a=8710&v=REL-0041-20181219.003944-userdebug&c=fastboot" first, your command is not correctly escaped
– Alvin Liang
Dec 19 at 2:27




try curl -s -u user:passwd "http://artifactory:8081/artifactory/api/search/gavc?a=8710&v=REL-0041-20181219.003944-userdebug&c=fastboot" first, your command is not correctly escaped
– Alvin Liang
Dec 19 at 2:27












Still access denied.
– Kuanlin Chen
Dec 19 at 2:31




Still access denied.
– Kuanlin Chen
Dec 19 at 2:31










1 Answer
1






active

oldest

votes


















2














It's several different questions.




  1. Your uri is not escaped so [1][2][2]+ messages means & treated as background execution, you need to quote uri with ""


  2. You use -s which means silent, so error messages are suppressed. Please remove -s and see what error curl encountered, solve them, and then you add back jq command.


  3. If your problem is essentially artifactory usage, you can add artifactory to your title.







share|improve this answer



















  • 1




    I tried curl -v -u user:passwd "url", it prints more log and seems like this problem caused by proxy.
    – Kuanlin Chen
    Dec 19 at 3:46













Your Answer








StackExchange.ready(function() {
var channelOptions = {
tags: "".split(" "),
id: "89"
};
initTagRenderer("".split(" "), "".split(" "), channelOptions);

StackExchange.using("externalEditor", function() {
// Have to fire editor after snippets, if snippets enabled
if (StackExchange.settings.snippets.snippetsEnabled) {
StackExchange.using("snippets", function() {
createEditor();
});
}
else {
createEditor();
}
});

function createEditor() {
StackExchange.prepareEditor({
heartbeatType: 'answer',
autoActivateHeartbeat: false,
convertImagesToLinks: true,
noModals: true,
showLowRepImageUploadWarning: true,
reputationToPostImages: 10,
bindNavPrevention: true,
postfix: "",
imageUploader: {
brandingHtml: "Powered by u003ca class="icon-imgur-white" href="https://imgur.com/"u003eu003c/au003e",
contentPolicyHtml: "User contributions licensed under u003ca href="https://creativecommons.org/licenses/by-sa/3.0/"u003ecc by-sa 3.0 with attribution requiredu003c/au003e u003ca href="https://stackoverflow.com/legal/content-policy"u003e(content policy)u003c/au003e",
allowUrls: true
},
onDemand: true,
discardSelector: ".discard-answer"
,immediatelyShowMarkdownHelp:true
});


}
});














draft saved

draft discarded


















StackExchange.ready(
function () {
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2faskubuntu.com%2fquestions%2f1102985%2fhow-to-debug-curl-access-denied%23new-answer', 'question_page');
}
);

Post as a guest















Required, but never shown

























1 Answer
1






active

oldest

votes








1 Answer
1






active

oldest

votes









active

oldest

votes






active

oldest

votes









2














It's several different questions.




  1. Your uri is not escaped so [1][2][2]+ messages means & treated as background execution, you need to quote uri with ""


  2. You use -s which means silent, so error messages are suppressed. Please remove -s and see what error curl encountered, solve them, and then you add back jq command.


  3. If your problem is essentially artifactory usage, you can add artifactory to your title.







share|improve this answer



















  • 1




    I tried curl -v -u user:passwd "url", it prints more log and seems like this problem caused by proxy.
    – Kuanlin Chen
    Dec 19 at 3:46


















2














It's several different questions.




  1. Your uri is not escaped so [1][2][2]+ messages means & treated as background execution, you need to quote uri with ""


  2. You use -s which means silent, so error messages are suppressed. Please remove -s and see what error curl encountered, solve them, and then you add back jq command.


  3. If your problem is essentially artifactory usage, you can add artifactory to your title.







share|improve this answer



















  • 1




    I tried curl -v -u user:passwd "url", it prints more log and seems like this problem caused by proxy.
    – Kuanlin Chen
    Dec 19 at 3:46
















2












2








2






It's several different questions.




  1. Your uri is not escaped so [1][2][2]+ messages means & treated as background execution, you need to quote uri with ""


  2. You use -s which means silent, so error messages are suppressed. Please remove -s and see what error curl encountered, solve them, and then you add back jq command.


  3. If your problem is essentially artifactory usage, you can add artifactory to your title.







share|improve this answer














It's several different questions.




  1. Your uri is not escaped so [1][2][2]+ messages means & treated as background execution, you need to quote uri with ""


  2. You use -s which means silent, so error messages are suppressed. Please remove -s and see what error curl encountered, solve them, and then you add back jq command.


  3. If your problem is essentially artifactory usage, you can add artifactory to your title.








share|improve this answer














share|improve this answer



share|improve this answer








edited Dec 19 at 3:06

























answered Dec 19 at 2:37









Alvin Liang

6618




6618








  • 1




    I tried curl -v -u user:passwd "url", it prints more log and seems like this problem caused by proxy.
    – Kuanlin Chen
    Dec 19 at 3:46
















  • 1




    I tried curl -v -u user:passwd "url", it prints more log and seems like this problem caused by proxy.
    – Kuanlin Chen
    Dec 19 at 3:46










1




1




I tried curl -v -u user:passwd "url", it prints more log and seems like this problem caused by proxy.
– Kuanlin Chen
Dec 19 at 3:46






I tried curl -v -u user:passwd "url", it prints more log and seems like this problem caused by proxy.
– Kuanlin Chen
Dec 19 at 3:46




















draft saved

draft discarded




















































Thanks for contributing an answer to Ask Ubuntu!


  • Please be sure to answer the question. Provide details and share your research!

But avoid



  • Asking for help, clarification, or responding to other answers.

  • Making statements based on opinion; back them up with references or personal experience.


To learn more, see our tips on writing great answers.





Some of your past answers have not been well-received, and you're in danger of being blocked from answering.


Please pay close attention to the following guidance:


  • Please be sure to answer the question. Provide details and share your research!

But avoid



  • Asking for help, clarification, or responding to other answers.

  • Making statements based on opinion; back them up with references or personal experience.


To learn more, see our tips on writing great answers.




draft saved


draft discarded














StackExchange.ready(
function () {
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2faskubuntu.com%2fquestions%2f1102985%2fhow-to-debug-curl-access-denied%23new-answer', 'question_page');
}
);

Post as a guest















Required, but never shown





















































Required, but never shown














Required, but never shown












Required, but never shown







Required, but never shown

































Required, but never shown














Required, but never shown












Required, but never shown







Required, but never shown







Popular posts from this blog

數位音樂下載

When can things happen in Etherscan, such as the picture below?

格利澤436b