private boolean isValidPassword(UploadRequestUrl data, String password) {
   if (data.isProtectedByPassword()) {
     if (password == null) return false;
     String hashedPassword = HashUtils.hashSha1withBase64(password.getBytes());
     return hashedPassword.equals(data.getPassword());
   }
   return true;
 }