关于DllImport的问题
[DllImport("crypt.dll")]
public static extern int DES(string key,int Encrypt,out string output,string input,int inputlength);
问:以上写法有问题吗?我怎样才能调用DLL中的DES方法,希望能给个调用的完整例子.
int WINAPI DES (
IN unsigned char *key,
IN int encrypt,
OUT unsigned char *output,
IN unsigned char *input,
IN unsigned int inputLen
);
参数说明:
key DES 密钥,共 8 字节。
encrypt 加解密标识。等于 0 表示解密,1 表示加密。0 对应 SES 函数_des_dec,1 对应 _des_enc。
output 生成的加密/解密结果,输出缓冲长度必须大于或者等于输入数据长度。
input 输入的待加解密数据。
inputLen 输入的待加解密数据长度
public static extern int DES(string key,int Encrypt,out string output,string input,int inputlength);
问:以上写法有问题吗?我怎样才能调用DLL中的DES方法,希望能给个调用的完整例子.
int WINAPI DES (
IN unsigned char *key,
IN int encrypt,
OUT unsigned char *output,
IN unsigned char *input,
IN unsigned int inputLen
);
参数说明:
key DES 密钥,共 8 字节。
encrypt 加解密标识。等于 0 表示解密,1 表示加密。0 对应 SES 函数_des_dec,1 对应 _des_enc。
output 生成的加密/解密结果,输出缓冲长度必须大于或者等于输入数据长度。
input 输入的待加解密数据。
inputLen 输入的待加解密数据长度
...全文
相关推荐
C# DllImport用法和路径问题 .docx
C# DllImport用法和路径问题 .docx,详细介绍了DllImport的用法,希望会对大家有帮助
C#中DllImport用法和路径问题 .rar
C#中DllImport用法和路径问题 .rar
c#的dllimport使用方法详解
DllImport是System.Runtime.InteropServices命名空间下的一个属性类,其功能是提供从非托管DLL导出的函数的必要调用信息
c#的dllimport使用方法详解.docx
c#的dllimport使用方法详解.docx
QT moc definition of dllimport static data member not allow.pdf
QT moc definition of dllimport static data member not allow


