commit | 402b5717ba59dbee0195d11ec9162ee88dc1baa6 | [log] [tgz] |
---|---|---|
author | manojkiraneda <manojkiran.eda@gmail.com> | Fri Dec 13 17:07:09 2019 +0530 |
committer | Ratan Gupta <ratagupt@linux.vnet.ibm.com> | Fri May 01 07:00:26 2020 +0000 |
tree | 3cbd6d207239326ec07906a2780acecd9f4eda5f | |
parent | 3fff6206a68bd50ea8750aa0d0321d43f9f06783 [diff] |
Implement GetLockList function in Lock Service - This commit implements the GetLockList rest API, by which any external client(with admin privelege) can get a list of locks obtained by providing the list of sessionID's as input. TestedBy: 1. Get the session ID from the Session Service curl -k -H "X-Auth-Token: $bmc_tokens" -X GET https://<ip>/redfish/v1/SessionService/Sessions/ { "@odata.context": "/redfish/v1/$metadata#SessionCollection.SessionCollection", "@odata.id": "/redfish/v1/SessionService/Sessions/", "@odata.type": "#SessionCollection.SessionCollection", "Description": "Session Collection", "Members": [ { "@odata.id": "/redfish/v1/SessionService/Sessions/qM4D0VfZt3" }, { "@odata.id": "/redfish/v1/SessionService/Sessions/bjYCiBSCIh" }, { "@odata.id": "/redfish/v1/SessionService/Sessions/LkfHvJFggY" }, { "@odata.id": "/redfish/v1/SessionService/Sessions/6RKP0aN5Gi" } ], "Members@odata.count": 4, "Name": "Session Collection" } 2. Use the GetLockList API to obtain the locks owned by a particular session. curl -k -H "X-Auth-Token:$bmc_tokens" -XPOST -H "Content-type: application/json" -d '{"SessionIDs": ["qM4D0VfZt3","bjYCiBSCIh"]}' https://127.0.0.1:2443/ibm/v1/HMC/LockService/Actions/LockService.GetLockList { "Records": [ { "HMCID": "hmc-id", "LockType": "Read", "ResourceID": 256, "SegmentFlags": [ { "LockFlag": "LockSame", "SegmentLength": 3 }, { "LockFlag": "DontLock", "SegmentLength": 4 } ], "SessionID": "qM4D0VfZt3", "TransactionID": 1 } ] } Signed-off-by: manojkiraneda <manojkiran.eda@gmail.com> Change-Id: I9375e2927938ab682df06ef60c823b279a7efead
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.