commit | f8aa3d2704d3897eb724dab9ac596af8b1f0e33e | [log] [tgz] |
---|---|---|
author | James Feist <james.feist@linux.intel.com> | Wed Apr 08 18:32:33 2020 -0700 |
committer | James Feist <james.feist@linux.intel.com> | Wed Apr 15 16:17:29 2020 +0000 |
tree | c2e3a2017b70cae0c6e139276e91afda0fe9dfcc | |
parent | 043a05366c1fe54d7b9ef883292d0cd2d01c66b2 [diff] |
Add CSRF check into websockets This adds CSRF check into websockets to avoid attacks on websockets. Tested: Could no longer use crosssite scripting to open websocket. KVM and SOL still work once web-ui changes are updated Change-Id: I325079ae3d4db2701671564dff733e034d2670d6 Signed-off-by: James Feist <james.feist@linux.intel.com>
This component attempts to be a "do everything" embedded webserver for openbmc.
At this time, the webserver implements a few interfaces:
BMCWeb is configured by setting -D
flags that correspond to options in bmcweb/CMakeLists.txt
and then compiling. For example, cmake -DBMCWEB_ENABLE_KVM=NO ...
followed by make
. The option names become C++ preprocessor symbols that control which code is compiled into the program.
When BMCWeb starts running, it reads persistent configuration data (such as UUID and session data) from a local file. If this is not usable, it generates a new configuration.
When BMCWeb SSL support is enabled and a usable certificate is not found, it will generate a self-sign a certificate before launching the server. The keys are generated by the secp384r1
algorithm. The certificate
C=US, O=OpenBMC, CN=testhost
,SHA-256
algorithm.