You are viewing a plain text version of this content. The canonical link for it is here.
Posted to common-commits@hadoop.apache.org by we...@apache.org on 2019/06/18 04:56:31 UTC
[hadoop] branch branch-3.1 updated: HADOOP-9157. Better option for
curl in hadoop-auth-examples. Contributed by Andras Bokor.
This is an automated email from the ASF dual-hosted git repository.
weichiu pushed a commit to branch branch-3.1
in repository https://gitbox.apache.org/repos/asf/hadoop.git
The following commit(s) were added to refs/heads/branch-3.1 by this push:
new 8f4204d HADOOP-9157. Better option for curl in hadoop-auth-examples. Contributed by Andras Bokor.
8f4204d is described below
commit 8f4204dc3bc5e44ee0ba7d645b069180a81a8747
Author: Wei-Chiu Chuang <we...@apache.org>
AuthorDate: Mon Jun 17 21:51:33 2019 -0700
HADOOP-9157. Better option for curl in hadoop-auth-examples. Contributed by Andras Bokor.
(cherry picked from commit f1c239c6a4c26e9057373b9b9400e54083290f65)
(cherry picked from commit e8db39b0e9ad66af3dada1ec7ad06b7d06f8e9f8)
---
hadoop-common-project/hadoop-auth/src/site/markdown/Examples.md | 6 +++---
1 file changed, 3 insertions(+), 3 deletions(-)
diff --git a/hadoop-common-project/hadoop-auth/src/site/markdown/Examples.md b/hadoop-common-project/hadoop-auth/src/site/markdown/Examples.md
index 4dad79d..4f29c8d 100644
--- a/hadoop-common-project/hadoop-auth/src/site/markdown/Examples.md
+++ b/hadoop-common-project/hadoop-auth/src/site/markdown/Examples.md
@@ -36,14 +36,14 @@ Login to the KDC using **kinit** and then use `curl` to fetch protected URL:
$ kinit
Please enter the password for tucu@LOCALHOST:
- $ curl --negotiate -u foo -b ~/cookiejar.txt -c ~/cookiejar.txt http://localhost:8080/hadoop-auth-examples/kerberos/who
+ $ curl --negotiate -u : -b ~/cookiejar.txt -c ~/cookiejar.txt http://$(hostname -f):8080/hadoop-auth-examples/kerberos/who
Enter host password for user 'tucu':
Hello Hadoop Auth Examples!
* The `--negotiate` option enables SPNEGO in `curl`.
-* The `-u foo` option is required but the user ignored (the principal
+* The `-u :` option is required but the user ignored (the principal
that has been kinit-ed is used).
* The `-b` and `-c` are use to store and send HTTP Cookies.
@@ -88,7 +88,7 @@ Try accessing protected resources using `curl`. The protected resources are:
$ curl http://localhost:8080/hadoop-auth-examples/simple/who?user.name=foo
- $ curl --negotiate -u foo -b ~/cookiejar.txt -c ~/cookiejar.txt http://localhost:8080/hadoop-auth-examples/kerberos/who
+ $ curl --negotiate -u : -b ~/cookiejar.txt -c ~/cookiejar.txt http://$(hostname -f):8080/hadoop-auth-examples/kerberos/who
### Accessing the server using the Java client example
---------------------------------------------------------------------
To unsubscribe, e-mail: common-commits-unsubscribe@hadoop.apache.org
For additional commands, e-mail: common-commits-help@hadoop.apache.org