You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@maven.apache.org by "elharo (via GitHub)" <gi...@apache.org> on 2026/07/01 15:35:44 UTC
[I] PropertyUtils.getPropertyValue() NPE on absent key [maven-filtering]
elharo opened a new issue, #358:
URL: https://github.com/apache/maven-filtering/issues/358
In src/main/java/org/apache/maven/shared/filtering/PropertyUtils.java, line 184:
String v = p.getProperty(k);
// ...
while ((idx = v.indexOf("${")) >= 0) {
If the key k does not exist in properties p, v is null and v.indexOf("${") throws NullPointerException. The calling code (lines 101104 of loadPropertyFile) iterates over fileProps.keySet() and passes each key with combinedProps which should contain that key. However, the recursive resolution at lines 199201 could extract a key name not present in combinedProps though that path is guarded by null checks (lines 221222). The initial call is safe in practice, but the method lacks a null guard for v at the entry point.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: issues-unsubscribe@maven.apache.org.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
Re: [I] PropertyUtils.getPropertyValue() NPE on absent key [maven-filtering]
Posted by "gnodet (via GitHub)" <gi...@apache.org>.
gnodet closed issue #358: PropertyUtils.getPropertyValue() NPE on absent key
URL: https://github.com/apache/maven-filtering/issues/358
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: issues-unsubscribe@maven.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org