code: async function(m, n, e, d) {
      if (n.cmp(m) <= 0) {
        throw new Error('Message size cannot exceed modulus size');
      }
      const nred = new BN.red(n);
      return m.toRed(nred).redPow(d).toArrayLike(Uint8Array, 'be', n.byteLength());
    }
docs: Create signature
  @param {BN} m message
  @param {BN} n RSA public modulus
  @param {BN} e RSA public exponent
  @param {BN} d RSA private exponent
  @returns {BN} RSA Signature
  @async