code: static void encode(DerOutputStream out, AlgorithmId algid, BitArray key)
          throws IOException {
              DerOutputStream tmp = new DerOutputStream();
              algid.encode(tmp);
              tmp.putUnalignedBitString(key);
              out.write(DerValue.tag_Sequence, tmp);
      }
docs: /*
  Produce SubjectPublicKey encoding from algorithm id and key material.