本代码是C#方法,通过开源C#BouncyCastle加密组件进行DES加解密。和JAVADES加解密互通。JAVA方法如下: publicstaticStringdesEncrypt(Stringsource,StringdesKey)throwsException{ try{ //从原始密匙数据创建DESKeySpec对象 SecretKeyFactorykeyFactory=SecretKeyFactory.getInstance("DES"); SecretKeysecurekey=keyFactory.generateSec