code: protected String createTmpFile(PMContext ctx) throws ConverterException {
          FileOutputStream fos = null;
          try {
              final PMSecurityUser user = ctx.getUser();
              byte[] value = (byte[]) ctx.getFieldValue();
              if (value == null) {
                  return null;
              }
              final String filename = user.getUsername() + "." + getConfig("type", "png");
              final String dir = "webapps/pm/cache/";
              final File directory = new File(dir);
              directory.mkdirs();
              final File tmpfile = new File(dir + filename);
              fos = new FileOutputStream(tmpfile);
              fos.write(value);
              return filename;
          } catch (Exception ex) {
              throw new ConverterException(ex);
          } finally {
              try {
                  if (fos != null) {
                      fos.close();
                  }
              } catch (IOException ex) {
                  throw new ConverterException(ex);
              }
          }
      }
docs: TODO avoid tmp file and build image online with another action