Skip to content
GitLab
Explore
Projects
Groups
Topics
Snippets
Projects
Groups
Topics
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
dSS - digitalSTROM Server
dss-mainline
Merge requests
!1597
Bka webserver cors
Code
Review changes
Check out branch
Download
Patches
Plain diff
Merged
Branislav Katreniak
requested to merge
brano/dss-mainline:bka-webserverCors
into
master
5 years ago
Overview
1
Commits
2
Pipelines
0
Changes
1
DSD-3028
0
0
Compare
master
master (base)
and
latest version
latest version
09e8e219
2 commits,
5 years ago
1 file
+
5
−
3
Expand all files
Preferences
Preferences
File browser
List view
Tree view
Compare changes
Inline
Side-by-side
Show whitespace changes
Show one file at a time
src/web/webserver.cpp
+
5
−
3
Options
View file @ 09e8e219
Edit in single-file editor
Open in Web IDE
Show full file
@@ -108,6 +108,7 @@ namespace dss {
#endif
sstream
<<
"
\r\n
"
;
}
sstream
<<
"Access-Control-Allow-Origin: *
\r\n
"
;
sstream
<<
"Content-Length: "
<<
intToString
(
length
)
<<
"
\r\n
"
;
for
(
const
auto
&
header
:
headers
)
{
for
(
const
auto
&
headerValue
:
header
.
second
)
{
@@ -222,9 +223,10 @@ namespace dss {
instantiateHandlers
();
std
::
vector
<
const
char
*>
mgOptions
{
"document_root"
,
configAliases
.
c_str
(),
//
"listening_ports"
,
configPorts
.
c_str
(),
//
"websocket_timeout_ms"
,
wsTimeout
.
c_str
(),
"enable_keep_alive"
,
"yes"
,
//
"document_root"
,
configAliases
.
c_str
(),
//
"listening_ports"
,
configPorts
.
c_str
(),
//
"websocket_timeout_ms"
,
wsTimeout
.
c_str
(),
//
"enable_keep_alive"
,
"yes"
,
//
};
std
::
string
sslCert
;
if
(
useSsl
)
{
Menu
Explore
Projects
Groups
Topics
Snippets