rzo1 commented on code in PR #8983:
URL: https://github.com/apache/storm/pull/8983#discussion_r3820533040


##########
external/storm-hdfs-oci/src/main/java/org/apache/storm/container/oci/LocalOrHdfsImageTagToManifestPlugin.java:
##########
@@ -271,12 +285,16 @@ public synchronized String getHashFromImageTag(String 
imageTag) {
 
         // 1) Go to local file
         // 2) Go to HDFS
-        // 3) Use tag as is/Assume tag is the hash
+        // 3) Use tag as is/Assume tag is the hash; only acceptable if the tag 
looks like a hash
         if ((hash = localImageToHashCache.get(imageTag)) != null) {
             return hash;
         } else if ((hash = hdfsImageToHashCache.get(imageTag)) != null) {
             return hash;
         } else {
+            if (!isValidHash(imageTag)) {
+                throw new IllegalArgumentException("Image tag " + imageTag

Review Comment:
   will change to an unchecked io exception to avoid changing the interfaces.



-- 
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: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to