Get Client IP Address from HTTP Server Request. How? #9314
Answered
by
suchislife801
suchislife801
asked this question in
Q&A
-
Using Deno's http server example, each request made returns the following request object about the client. Where do I get the Client's request IP number from?
Thank you, Vini |
Beta Was this translation helpful? Give feedback.
Answered by
suchislife801
Jan 29, 2021
Replies: 2 comments 1 reply
-
Ahhh... ok. So it's stored in the headers but to obtain it, you must use more than just dot notation. Example: |
Beta Was this translation helpful? Give feedback.
1 reply
Answer selected by
suchislife801
-
There is conn.remoteAddr |
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Ahhh... ok.
So it's stored in the headers but to obtain it, you must use more than just dot notation.
Example:
const clientIPAddress: string = httpRequest.headers.get('host')