Skip to content
GitLab
Explore
Sign in
Register
Primary navigation
Search or go to…
Project
M
mongoose
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Package registry
Container Registry
Model registry
Operate
Environments
Terraform modules
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Admin message
Gitlab has been updated. More info
here
and
there
.
Show more breadcrumbs
Ganil-acq
GANILinux
linux-service
library
mongoose
Commits
3bf7b817
Commit
3bf7b817
authored
3 years ago
by
Sergey Lyubka
Browse files
Options
Downloads
Patches
Plain Diff
Update docs
parent
477e48bf
No related branches found
No related tags found
No related merge requests found
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
docs/README.md
+23
-1
23 additions, 1 deletion
docs/README.md
with
23 additions
and
1 deletion
docs/README.md
+
23
−
1
View file @
3bf7b817
...
...
@@ -1073,7 +1073,7 @@ is that there is no QoS in unsubscribe request.
## TLS
### mg\_tls\_
init()
###
struct
mg\_tls\_
opts
```
c
struct
mg_tls_opts
{
...
...
@@ -1083,6 +1083,28 @@ struct mg_tls_opts {
const
char
*
ciphers
;
// Cipher list
struct
mg_str
srvname
;
// If not empty, enables server name verification
};
```
TLS initialisation structure:
-
`ca`
- Certificate Authority. Can be a filename, or a string. Used to verify
a certificate that other end sends to us. If NULL, then certificate checking
is disabled
-
`cert`
- our own certificate. Can be a filename, or a string. If NULL, then
we don't authenticate with the other peer
-
`certkey`
- a key for a
`cert`
. Sometimes, a certificate and its key are
bundled in a single .pem file, in which case the values for
`cert`
and
`certkey`
could be the same
-
`ciphers`
- a list of allowed ciphers
-
`srvname`
- enable server name verification
NOTE: if both
`ca`
and
`cert`
are set, then so-called two-way TLS is enabled,
when both sides authenticate with each other. Usually, server-side connections
set both
`ca`
and
`cert`
, whilst client-side - only
`ca`
.
### mg\_tls\_init()
```
c
int
mg_tls_init
(
struct
mg_connection
*
c
,
struct
mg_tls_opts
*
opts
);
```
...
...
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