Want to win a PS4? Go Premium and enter to win our High-Tech Treats giveaway. Enter to Win

x
?
Solved

Could you explain this curl script?

Posted on 2014-03-29
4
Medium Priority
?
660 Views
Last Modified: 2014-03-29
Hi

I have a curl script and it works
curl -i -X POST admin:admin@localhost/auth

What is "admin:admin"? How do I know the parameter name for this?
Shouldn't it be "username=admin&password=admin"?


Thanks
Jamie
0
Comment
Question by:jamie_lynn
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
4 Comments
 
LVL 80

Accepted Solution

by:
arnold earned 2000 total points
ID: 39964309
admin:admin is username:password when you use for services such as http, FTP you use username:password@www.somesite.com
-X POST tells the method in this case you will be passing data as part of your request.
-i is include HTTP headers.

Man curl in your favorite search engine
Or locally on the system or info curl

http://linux.die.net/man/1/curl
0
 

Author Comment

by:jamie_lynn
ID: 39964313
Oh I see.  it is using http basic authentication.
0

Featured Post

Free Tool: ZipGrep

ZipGrep is a utility that can list and search zip (.war, .ear, .jar, etc) archives for text patterns, without the need to extract the archive's contents.

One of a set of tools we're offering as a way to say thank you for being a part of the community.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

In this post we will learn different types of Android Layout and some basics of an Android App.
3 proven steps to speed up Magento powered sites. The article focus is on optimizing time to first byte (TTFB), full page caching and configuring server for optimal performance.
The viewer will learn how to count occurrences of each item in an array.
The viewer will learn how to create and use a small PHP class to apply a watermark to an image. This video shows the viewer the setup for the PHP watermark as well as important coding language. Continue to Part 2 to learn the core code used in creat…
Suggested Courses

610 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question