]> git-server-git.apps.pok.os.sepia.ceph.com Git - ceph.git/commit
rgw: tempurl signature fixes: support sha256 and sha512
authorMarcus Watts <mwatts@redhat.com>
Mon, 22 Aug 2022 07:38:18 +0000 (03:38 -0400)
committerMarcus Watts <mwatts@redhat.com>
Thu, 18 Jan 2024 05:42:59 +0000 (00:42 -0500)
commite2023d28dc6e6e835303716e7235df720d33a01c
treef1574124d7fce1afd4a38ebc7e4eb187d186b3db
parent86c2c9a0aa6fc709022b4beb4fcd456c1320e03a
rgw: tempurl signature fixes: support sha256 and sha512

The latest openstack swift logic supports sha256 and sha512 checksums
for tempurl and formpost, which can be either hexadecimal or
hashname:base64.  This adds logic to inspect the incoming signature
for type and to internally construct the same hash to compare.

Also:: fixes an incidental crash if a malformed swift path does not
contain an object name.

Fixes: https://tracker.ceph.com/issues/56564
Signed-off-by: Marcus Watts <mwatts@redhat.com>
src/rgw/rgw_swift_auth.cc
src/rgw/rgw_swift_auth.h