How can I get the "Realm" message sent in the WWW-Authenticate header by a server requesting HTTP Basic authentication?
closed as not a real question by minitech♦, DaveShaw, Kyle Trauberman, casperOne♦ Dec 9 '11 at 3:58It's difficult to tell what is being asked here. This question is ambiguous, vague, incomplete, overly broad, or rhetorical and cannot be reasonably answered in its current form. For help clarifying this question so that it can be reopened, visit the help center. If this question can be reworded to fit the rules in the help center, please edit the question. |
|||||||||
|
Not really sure what the issue the down-voters have with this question really is. Here's the rough code to get the WWW-Authenticate header that contains the Basic authentication realm. Extracting the actual realm value from the header is left as an exercise, but should be quite straightforward (e.g. using regular expression).
|
|||||||||
|
I'm assuming you want to create a Web Request with Basic Authentication. If that's the correct assumption, the following code is what you need:
|
|||
|