docs: private static byte[] readUntil(@NotNull SequentialReader reader, @NotNull byte[] sentinel) throws IOException
      {
          ByteArrayOutputStream bytes = new ByteArrayOutputStream();
  
          final int length = sentinel.length;
          int depth = 0;
  
          while (depth != length) {
              byte b = reader.getByte();
              if (b == sentinel[depth])
                  depth++;
              else
                  depth = 0;
              bytes.write(b);
          }
  
          return bytes.toByteArray();
      }