MCPcopy Create free account
hub / github.com/apache/httpd / ap_md5digest

Function ap_md5digest

server/util_md5.c:150–165  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

148}
149
150AP_DECLARE(char *) ap_md5digest(apr_pool_t *p, apr_file_t *infile)
151{
152 apr_md5_ctx_t context;
153 unsigned char buf[4096]; /* keep this a multiple of 64 */
154 apr_size_t nbytes;
155 apr_off_t offset = 0L;
156
157 apr_md5_init(&context);
158 nbytes = sizeof(buf);
159 while (apr_file_read(infile, buf, &nbytes) == APR_SUCCESS) {
160 apr_md5_update(&context, buf, nbytes);
161 nbytes = sizeof(buf);
162 }
163 apr_file_seek(infile, APR_SET, &offset);
164 return ap_md5contextTo64(p, &context);
165}
166

Callers 2

default_handlerFunction · 0.85
util_md5.hFile · 0.85

Calls 1

ap_md5contextTo64Function · 0.85

Tested by

no test coverage detected