comparison Core/Toolbox.h @ 1479:8f28a1cd2354

possibility to disable md5 and base64 support in the toolbox
author Sebastien Jodogne <s.jodogne@gmail.com>
date Sun, 02 Aug 2015 12:20:27 +0200
parents 8dc80ba768aa
children 596927722403
comparison
equal deleted inserted replaced
1478:1011bd6ab00b 1479:8f28a1cd2354
88 std::string FlattenUri(const UriComponents& components, 88 std::string FlattenUri(const UriComponents& components,
89 size_t fromLevel = 0); 89 size_t fromLevel = 0);
90 90
91 uint64_t GetFileSize(const std::string& path); 91 uint64_t GetFileSize(const std::string& path);
92 92
93 #if !defined(ORTHANC_ENABLE_MD5) || ORTHANC_ENABLE_MD5 == 1
93 void ComputeMD5(std::string& result, 94 void ComputeMD5(std::string& result,
94 const std::string& data); 95 const std::string& data);
95 96
96 void ComputeMD5(std::string& result, 97 void ComputeMD5(std::string& result,
97 const void* data, 98 const void* data,
98 size_t length); 99 size_t length);
100 #endif
99 101
100 void ComputeSHA1(std::string& result, 102 void ComputeSHA1(std::string& result,
101 const std::string& data); 103 const std::string& data);
102 104
103 bool IsSHA1(const char* str, 105 bool IsSHA1(const char* str,
104 size_t size); 106 size_t size);
105 107
106 bool IsSHA1(const std::string& s); 108 bool IsSHA1(const std::string& s);
107 109
110 #if !defined(ORTHANC_ENABLE_BASE64) || ORTHANC_ENABLE_BASE64 == 1
108 void DecodeBase64(std::string& result, 111 void DecodeBase64(std::string& result,
109 const std::string& data); 112 const std::string& data);
110 113
111 void EncodeBase64(std::string& result, 114 void EncodeBase64(std::string& result,
112 const std::string& data); 115 const std::string& data);
116 #endif
113 117
114 std::string GetPathToExecutable(); 118 std::string GetPathToExecutable();
115 119
116 std::string GetDirectoryOfExecutable(); 120 std::string GetDirectoryOfExecutable();
117 121