mirror of
https://github.com/warmcat/libwebsockets.git
synced 2025-03-16 00:00:07 +01:00
lextable add x-real-ip
Signed-off-by: Andy Green <andy.green@linaro.org>
This commit is contained in:
parent
8d5351a0c4
commit
4e9c7f3504
4 changed files with 767 additions and 737 deletions
|
@ -220,6 +220,9 @@ lws_adopt_socket(struct lws_context *context, lws_sockfd_type accept_fd)
|
||||||
allows foreign sockets accepted by non-lws code to be adopted by lws as if they
|
allows foreign sockets accepted by non-lws code to be adopted by lws as if they
|
||||||
had just been accepted by lws' own listen socket.
|
had just been accepted by lws' own listen socket.
|
||||||
|
|
||||||
|
9) X-Real-IP: header has been added as WSI_TOKEN_HTTP_X_REAL_IP
|
||||||
|
|
||||||
|
|
||||||
User api changes
|
User api changes
|
||||||
----------------
|
----------------
|
||||||
|
|
||||||
|
@ -255,6 +258,10 @@ It can be NULL if there are no options on the extension. Extension internal
|
||||||
info is part of the public abi because extensions may be implemented outside
|
info is part of the public abi because extensions may be implemented outside
|
||||||
the library.
|
the library.
|
||||||
|
|
||||||
|
8) WSI_TOKEN_PROXY enum was accidentally defined to collide with another token
|
||||||
|
of value 73. That's now corrected and WSI_TOKEN_PROXY moved to his own place at
|
||||||
|
77.
|
||||||
|
|
||||||
|
|
||||||
v1.6.0-chrome48-firefox42
|
v1.6.0-chrome48-firefox42
|
||||||
=======================
|
=======================
|
||||||
|
|
|
@ -79,12 +79,16 @@ static const char *set[] = {
|
||||||
"vary:",
|
"vary:",
|
||||||
"via:",
|
"via:",
|
||||||
"www-authenticate:",
|
"www-authenticate:",
|
||||||
"proxy ",
|
|
||||||
|
|
||||||
"patch",
|
"patch",
|
||||||
"put",
|
"put",
|
||||||
"delete",
|
"delete",
|
||||||
|
|
||||||
|
"uri-args", /* fake header used for uri-only storage */
|
||||||
|
|
||||||
|
"proxy ",
|
||||||
|
"x-real-ip:",
|
||||||
|
|
||||||
"", /* not matchable */
|
"", /* not matchable */
|
||||||
|
|
||||||
};
|
};
|
||||||
|
|
1469
lib/lextable.h
1469
lib/lextable.h
File diff suppressed because it is too large
Load diff
|
@ -502,8 +502,6 @@ struct lws_tokens {
|
||||||
};
|
};
|
||||||
|
|
||||||
/*
|
/*
|
||||||
* don't forget to update test server header dump accordingly
|
|
||||||
*
|
|
||||||
* these have to be kept in sync with lextable.h / minilex.c
|
* these have to be kept in sync with lextable.h / minilex.c
|
||||||
*
|
*
|
||||||
* NOTE: These public enums are part of the abi. If you want to add one,
|
* NOTE: These public enums are part of the abi. If you want to add one,
|
||||||
|
@ -585,24 +583,26 @@ enum lws_token_indexes {
|
||||||
WSI_TOKEN_HTTP_VARY = 70,
|
WSI_TOKEN_HTTP_VARY = 70,
|
||||||
WSI_TOKEN_HTTP_VIA = 71,
|
WSI_TOKEN_HTTP_VIA = 71,
|
||||||
WSI_TOKEN_HTTP_WWW_AUTHENTICATE = 72,
|
WSI_TOKEN_HTTP_WWW_AUTHENTICATE = 72,
|
||||||
WSI_TOKEN_PROXY,
|
|
||||||
|
|
||||||
WSI_TOKEN_PATCH_URI = 73,
|
WSI_TOKEN_PATCH_URI = 73,
|
||||||
WSI_TOKEN_PUT_URI = 74,
|
WSI_TOKEN_PUT_URI = 74,
|
||||||
WSI_TOKEN_DELETE_URI = 75,
|
WSI_TOKEN_DELETE_URI = 75,
|
||||||
|
|
||||||
WSI_TOKEN_HTTP_URI_ARGS = 76,
|
WSI_TOKEN_HTTP_URI_ARGS = 76,
|
||||||
|
WSI_TOKEN_PROXY = 77,
|
||||||
/* use token storage to stash these */
|
WSI_TOKEN_HTTP_X_REAL_IP = 78,
|
||||||
|
|
||||||
_WSI_TOKEN_CLIENT_SENT_PROTOCOLS = 77,
|
|
||||||
_WSI_TOKEN_CLIENT_PEER_ADDRESS = 78,
|
|
||||||
_WSI_TOKEN_CLIENT_URI = 79,
|
|
||||||
_WSI_TOKEN_CLIENT_HOST = 80,
|
|
||||||
_WSI_TOKEN_CLIENT_ORIGIN = 81,
|
|
||||||
|
|
||||||
/****** add new things just above ---^ ******/
|
/****** add new things just above ---^ ******/
|
||||||
|
|
||||||
|
/* use token storage to stash these internally, not for
|
||||||
|
* user use */
|
||||||
|
|
||||||
|
_WSI_TOKEN_CLIENT_SENT_PROTOCOLS,
|
||||||
|
_WSI_TOKEN_CLIENT_PEER_ADDRESS,
|
||||||
|
_WSI_TOKEN_CLIENT_URI,
|
||||||
|
_WSI_TOKEN_CLIENT_HOST,
|
||||||
|
_WSI_TOKEN_CLIENT_ORIGIN,
|
||||||
|
|
||||||
/* always last real token index*/
|
/* always last real token index*/
|
||||||
WSI_TOKEN_COUNT,
|
WSI_TOKEN_COUNT,
|
||||||
|
|
||||||
|
|
Loading…
Add table
Reference in a new issue