import { sm4 as SM4 } from 'gm-crypt' 

const key = "GJstSK_YBD=gSOFT"
const mode = "ecb"
const cipherType = "base64"

// 加密方法
export function encrypt(text) {
  const sm4Config = {
    key: key,
    mode: mode,
    cipherType: cipherType
  }
  const sm4 = new SM4(sm4Config)
  return sm4.encrypt(text)
}