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
48404579
Commit
48404579
authored
Mar 05, 2011
by
valenok
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Passing request_info with user_data to MG_INIT_SSL
parent
80d9fbcd
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
4 additions
and
1 deletion
+4
-1
mongoose.c
mongoose.c
+4
-1
No files found.
mongoose.c
View file @
48404579
...
...
@@ -3551,6 +3551,7 @@ static int load_dll(struct mg_context *ctx, const char *dll_name,
// Dynamically load SSL library. Set up ctx->ssl_ctx pointer.
static
int
set_ssl_option
(
struct
mg_context
*
ctx
)
{
struct
mg_request_info
request_info
;
SSL_CTX
*
CTX
;
int
i
,
size
;
const
char
*
pem
=
ctx
->
config
[
SSL_CERTIFICATE
];
...
...
@@ -3574,8 +3575,10 @@ static int set_ssl_option(struct mg_context *ctx) {
if
((
CTX
=
SSL_CTX_new
(
SSLv23_server_method
()))
==
NULL
)
{
cry
(
fc
(
ctx
),
"SSL_CTX_new error: %s"
,
ssl_error
());
}
else
if
(
ctx
->
user_callback
!=
NULL
)
{
memset
(
&
request_info
,
0
,
sizeof
(
request_info
));
request_info
.
user_data
=
ctx
->
user_data
;
ctx
->
user_callback
(
MG_INIT_SSL
,
(
struct
mg_connection
*
)
CTX
,
ctx
->
user_data
);
&
request_info
);
}
if
(
CTX
!=
NULL
&&
SSL_CTX_use_certificate_file
(
CTX
,
pem
,
...
...
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