code: public Map<String, java.security.cert.Extension> getExtensions() {
          if (extensions == null) {
              return Collections.emptyMap();
          }
          Collection<Extension> exts = extensions.getAllExtensions();
          Map<String, java.security.cert.Extension> map = new TreeMap<>();
          for (Extension ext : exts) {
              map.put(ext.getId(), ext);
          }
          return map;
      }
docs: Returns all extensions for this entry in a map
  @return the extension map, can be empty, but not null