If a given schema-valid policy document contains an empty description
element ([Description][/Description] or [Description/]), AbstractPolicy
throws a NullPointerException in its constructor.
According to the XACML policy schema provided by OASIS, the datatype of the
Description element is xs:string. And according to
http://www.w3.org/TR/xmlschema-2/ an empty xs:string is a valid xs:string.
So either the schema should be updated to disallow empty strings, or the
parsing should account for this case.
The attached AbstractPolicy.java contains a small modification to the 1.2
source release's code (around line 220) which takes the latter route: it
checks for a null child and treats it the same as if the Description
element had not been specified at all in the policy document.
Nobody/Anonymous
None
None
Public
|
Date: 2006-11-28 14:47
|
| Filename | Description | Download |
|---|---|---|
| AbstractPolicy.java | Patched AbstractPolicy.java that doesn't throw NPE when Description is empty | Download |
| Field | Old Value | Date | By |
|---|---|---|---|
| status_id | Open | 2006-11-28 14:47 | sethp |
| resolution_id | None | 2006-11-28 14:47 | sethp |
| close_date | - | 2006-11-28 14:47 | sethp |
| File Added | 203914: AbstractPolicy.java | 2006-11-22 03:23 | cwilper |
Copyright © 2009 Geeknet, Inc. All rights reserved. Terms of Use