⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 base64t.h

📁 伯克利做的SFTP安全文件传输协议
💻 H
字号:
// base64t.h// base-64 functions, Transform interface// copyright SafeTP Development Group, Inc., 2000  Terms of use are as specified in license.txt#ifndef __BASE64T_H#define __BASE64T_H#include "trans.h"         // Trans#include "str.h"           // string// encode 8-bit data as 6-bit dataclass Base64Encoder : public Trans {public:  virtual int minInputSize() const;  virtual int maxInputSize() const;  virtual int minOutputSize(int inputSize) const;  virtual int maxOutputSize(int inputSize) const;  virtual void trans(DataBlock &data);};// decode 6-bit data to 8-bit dataclass Base64Decoder : public Trans {public:  virtual int minInputSize() const;  virtual int maxInputSize() const;  virtual int minOutputSize(int inputSize) const;  virtual int maxOutputSize(int inputSize) const;  virtual void trans(DataBlock &data);};// globally accessible objects// these don't have state, so even though they're not marked const,// they are thread-safeextern Base64Encoder base64encoder;extern Base64Decoder base64decoder;extern TransPair base64pair;// some slightly different interfacesvoid base64decode(DataBlock &dest, char const *srcEncoded);  // allocate and write to 'dest'string base64encode(DataBlock const &src);  // allocate and write to 'dest', does not modify 'src'// use this, instead of strlen, to retrieve the buffer length of// some base64 data (it includes the null terminator in the length,// because the base64 process produces a null-terminated string)int base64length(char const *base64EncodedString);#endif // __BASE64T_H

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -