message: stay friendlier with Buffer webpack conversions
diff: @@ -59,7 +59,8 @@ export function encryptECIES(publicKey: string, content: string | Buffer) {
  const ephemeralPK = ephemeralSK.getPublic()
  const sharedSecret = ephemeralSK.derive(ecPK)
  - const sharedKeys = sharedSecretToKeys(sharedSecret.toBuffer())
  + const sharedKeys = sharedSecretToKeys(
  + new Buffer(sharedSecret.toString('hex'), 'hex'))
  const initializationVector = crypto.randomBytes(16)
  @@ -89,7 +90,8 @@ export function decryptECIES(privateKey: string, cipherObject: string ) {
  const ecSK = ecurve.keyFromPrivate(privateKey, 'hex')
  const ephemeralPK = ecurve.keyFromPublic(cipherObject.ephemeralPK, 'hex').getPublic()
  const sharedSecret = ecSK.derive(ephemeralPK)
  - const sharedKeys = sharedSecretToKeys(sharedSecret.toBuffer())
  + const sharedKeys = sharedSecretToKeys(
  + new Buffer(sharedSecret.toString('hex'), 'hex'))
  const ivBuffer = new Buffer(cipherObject.iv, 'hex')
  const cipherTextBuffer = new Buffer(cipherObject.cipherText, 'hex')
  