Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
L
libwebsockets
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Container registry
Model registry
Operate
Environments
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Issue analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Terms and privacy
Keyboard shortcuts
?
Snippets
Groups
Projects
This is an archived project. Repository and other project resources are read-only.
Show more breadcrumbs
Fork
libwebsockets
Commits
d7fddada
Commit
d7fddada
authored
9 years ago
by
Andy Green
Browse files
Options
Downloads
Patches
Plain Diff
context creation info add ecdh_curve
Signed-off-by:
Andy Green
<
andy.green@linaro.org
>
parent
79afbe34
No related branches found
No related tags found
No related merge requests found
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
changelog
+8
-0
8 additions, 0 deletions
changelog
lib/libwebsockets.h
+2
-0
2 additions, 0 deletions
lib/libwebsockets.h
lib/ssl.c
+3
-0
3 additions, 0 deletions
lib/ssl.c
with
13 additions
and
0 deletions
changelog
+
8
−
0
View file @
d7fddada
Changelog
Changelog
---------
---------
User API additions
------------------
1) There's a new member in struct lws_context_creation_info, ecdh_curve,
which lets you set the name of the ECDH curve OpenSSL should use. By
default (if you leave ecdh_curve NULL) it will use "prime256v1"
v1.7.0
v1.7.0
======
======
...
...
This diff is collapsed.
Click to expand it.
lib/libwebsockets.h
+
2
−
0
View file @
d7fddada
...
@@ -1319,6 +1319,7 @@ extern int lws_extension_callback_pm_deflate(
...
@@ -1319,6 +1319,7 @@ extern int lws_extension_callback_pm_deflate(
* library are protected from hanging forever by timeouts. If
* library are protected from hanging forever by timeouts. If
* nonzero, this member lets you set the timeout used in seconds.
* nonzero, this member lets you set the timeout used in seconds.
* Otherwise a default timeout is used.
* Otherwise a default timeout is used.
* @ecdh_curve: if NULL, defaults to initializing server with "prime256v1"
*/
*/
struct
lws_context_creation_info
{
struct
lws_context_creation_info
{
...
@@ -1353,6 +1354,7 @@ struct lws_context_creation_info {
...
@@ -1353,6 +1354,7 @@ struct lws_context_creation_info {
unsigned
int
count_threads
;
unsigned
int
count_threads
;
unsigned
int
fd_limit_per_thread
;
unsigned
int
fd_limit_per_thread
;
unsigned
int
timeout_secs
;
unsigned
int
timeout_secs
;
const
char
*
ecdh_curve
;
/* Add new things just above here ---^
/* Add new things just above here ---^
* This is part of the ABI, don't needlessly break compatibility
* This is part of the ABI, don't needlessly break compatibility
...
...
This diff is collapsed.
Click to expand it.
lib/ssl.c
+
3
−
0
View file @
d7fddada
...
@@ -144,6 +144,9 @@ lws_context_ssl_init_ecdh_curve(struct lws_context_creation_info *info,
...
@@ -144,6 +144,9 @@ lws_context_ssl_init_ecdh_curve(struct lws_context_creation_info *info,
int
ecdh_nid
;
int
ecdh_nid
;
const
char
*
ecdh_curve
=
"prime256v1"
;
const
char
*
ecdh_curve
=
"prime256v1"
;
if
(
info
->
ecdh_curve
)
ecdh_curve
=
info
->
ecdh_curve
;
ecdh_nid
=
OBJ_sn2nid
(
ecdh_curve
);
ecdh_nid
=
OBJ_sn2nid
(
ecdh_curve
);
if
(
NID_undef
==
ecdh_nid
)
{
if
(
NID_undef
==
ecdh_nid
)
{
lwsl_err
(
"SSL: Unknown curve name '%s'"
,
ecdh_curve
);
lwsl_err
(
"SSL: Unknown curve name '%s'"
,
ecdh_curve
);
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment