Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Contribute to GitLab
Sign in
Toggle navigation
M
mongoose
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
esp
mongoose
Commits
5a037648
Commit
5a037648
authored
Aug 31, 2010
by
valenok
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
rearranged options list in alphabetical order
parent
75b6717d
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
18 additions
and
18 deletions
+18
-18
mongoose.c
mongoose.c
+18
-18
No files found.
mongoose.c
View file @
5a037648
...
@@ -348,35 +348,35 @@ struct socket {
...
@@ -348,35 +348,35 @@ struct socket {
};
};
enum
{
enum
{
DOCUMENT_ROOT
,
LISTENING_PORTS
,
INDEX_FILES
,
SSL_CERTIFICATE
,
CGI_EXTENSIONS
,
CGI_EXTENSIONS
,
CGI_ENVIRONMENT
,
PUT_DELETE_PASSWORDS_FILE
,
CGI_INTERPRETER
,
CGI_INTERPRETER
,
CGI_ENVIRONMENT
,
SSI_EXTENSIONS
,
AUTHENTICATION_DOMAIN
,
PROTECT_URI
,
AUTHENTICATION_DOMAIN
,
SSI_EXTENSIONS
,
ACCESS_LOG_FILE
,
URI_PROTECTION
,
GLOBAL_PASSWORDS_FILE
,
PUT_DELETE_PASSWORDS_FILE
,
ENABLE_DIRECTORY_LISTING
,
ERROR_LOG_FILE
,
GLOBAL_PASSWORDS_FILE
,
INDEX_FILES
,
ACCESS_LOG_FILE
,
ERROR_LOG_FILE
,
ACCESS_CONTROL_LIST
,
RUN_AS_USER
,
ENABLE_KEEP_ALIVE
,
ACCESS_CONTROL_LIST
,
EXTRA_MIME_TYPES
,
LISTENING_PORTS
,
EXTRA_MIME_TYPES
,
ENABLE_DIRECTORY_LISTING
,
ENABLE_KEEP_ALIVE
,
NUM_THREADS
,
DOCUMENT_ROOT
,
SSL_CERTIFICATE
,
NUM_THREADS
,
RUN_AS_USER
,
NUM_OPTIONS
NUM_OPTIONS
};
};
static
const
char
*
config_options
[]
=
{
static
const
char
*
config_options
[]
=
{
"r"
,
"document_root"
,
"."
,
"p"
,
"listening_ports"
,
"8080"
,
"i"
,
"index_files"
,
"index.html,index.htm,index.cgi"
,
"s"
,
"ssl_certificate"
,
NULL
,
"C"
,
"cgi_extensions"
,
".cgi,.pl,.php"
,
"C"
,
"cgi_extensions"
,
".cgi,.pl,.php"
,
"I"
,
"cgi_interpreter"
,
NULL
,
"E"
,
"cgi_environment"
,
NULL
,
"E"
,
"cgi_environment"
,
NULL
,
"S"
,
"ssi_extensions"
,
".shtml,.shtm"
,
"R"
,
"authentication_domain"
,
"mydomain.com"
,
"P"
,
"protect_uri"
,
NULL
,
"g"
,
"global_passwords_file"
,
NULL
,
"G"
,
"put_delete_passwords_file"
,
NULL
,
"G"
,
"put_delete_passwords_file"
,
NULL
,
"I"
,
"cgi_interpreter"
,
NULL
,
"P"
,
"protect_uri"
,
NULL
,
"R"
,
"authentication_domain"
,
"mydomain.com"
,
"S"
,
"ssi_extensions"
,
".shtml,.shtm"
,
"a"
,
"access_log_file"
,
NULL
,
"a"
,
"access_log_file"
,
NULL
,
"d"
,
"enable_directory_listing"
,
"yes"
,
"e"
,
"error_log_file"
,
NULL
,
"e"
,
"error_log_file"
,
NULL
,
"g"
,
"global_passwords_file"
,
NULL
,
"i"
,
"index_files"
,
"index.html,index.htm,index.cgi"
,
"k"
,
"enable_keep_alive"
,
"no"
,
"l"
,
"access_control_list"
,
NULL
,
"l"
,
"access_control_list"
,
NULL
,
"u"
,
"run_as_user"
,
NULL
,
"m"
,
"extra_mime_types"
,
NULL
,
"m"
,
"extra_mime_types"
,
NULL
,
"d"
,
"enable_directory_listing"
,
"yes"
,
"p"
,
"listening_ports"
,
"8080"
,
"k"
,
"enable_keep_alive"
,
"no"
,
"r"
,
"document_root"
,
"."
,
"s"
,
"ssl_certificate"
,
NULL
,
"t"
,
"num_threads"
,
"10"
,
"t"
,
"num_threads"
,
"10"
,
"u"
,
"run_as_user"
,
NULL
,
NULL
NULL
};
};
...
@@ -2106,7 +2106,7 @@ static int check_authorization(struct mg_connection *conn, const char *path) {
...
@@ -2106,7 +2106,7 @@ static int check_authorization(struct mg_connection *conn, const char *path) {
fp
=
NULL
;
fp
=
NULL
;
authorized
=
1
;
authorized
=
1
;
list
=
conn
->
ctx
->
config
[
URI_PROTECTION
];
list
=
conn
->
ctx
->
config
[
PROTECT_URI
];
while
((
list
=
next_option
(
list
,
&
uri_vec
,
&
filename_vec
))
!=
NULL
)
{
while
((
list
=
next_option
(
list
,
&
uri_vec
,
&
filename_vec
))
!=
NULL
)
{
if
(
!
memcmp
(
conn
->
request_info
.
uri
,
uri_vec
.
ptr
,
uri_vec
.
len
))
{
if
(
!
memcmp
(
conn
->
request_info
.
uri
,
uri_vec
.
ptr
,
uri_vec
.
len
))
{
(
void
)
mg_snprintf
(
conn
,
fname
,
sizeof
(
fname
),
"%.*s"
,
(
void
)
mg_snprintf
(
conn
,
fname
,
sizeof
(
fname
),
"%.*s"
,
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment