Project

General

Profile

Bug #1054

RGW segfaults if the Owner field is not set in an ACL

Added by Colin McCabe almost 9 years ago. Updated almost 9 years ago.

Status:
Duplicate
Priority:
High
Assignee:
Category:
-
Target version:
% Done:

0%

Source:
Tags:
Backport:
Regression:
No
Severity:
3 - minor
Reviewed:
Affected Versions:
ceph-qa-suite:
Pull request ID:
Crash signature:

Description

The following code explains the situation quite well, I think:

void RGWAccessControlPolicy::xml_end(const char *el) {           
  acl = *(RGWAccessControlList *)find_first("AccessControlList");
  owner = *(ACLOwner *)find_first("Owner");
} 

We have no idea whether find_first will find either of these things!

If AccessControlList isn't found, of course, the XML is malformed. But that still should not cause us to segfault.

Unfortunately, expat is not a validating XML parser, so we can't just validate against a schema.

History

#1 Updated by Colin McCabe almost 9 years ago

  • Status changed from New to Duplicate

re-created this as a subtask of 1053 (which I always wanted it to be)

Apparently you can't subtask-ize things after creating them.

See #1055

Also available in: Atom PDF