Lines Matching defs:sr
88 isc_region_t sr;
97 dns_rdata_toregion(rdata, &sr);
102 n = uint16_fromregion(&sr);
103 isc_region_consume(&sr, 2);
110 n = uint8_fromregion(&sr);
111 isc_region_consume(&sr, 1);
118 n = uint8_fromregion(&sr);
119 isc_region_consume(&sr, 1);
129 RETERR(isc_hex_totext(&sr, tctx->width - 2, tctx->linebreak, target));
137 isc_region_t sr;
146 isc_buffer_activeregion(source, &sr);
151 if (sr.length < 4 ||
152 (sr.base[3] == DNS_DSDIGEST_SHA1 &&
153 sr.length < 4 + ISC_SHA1_DIGESTLENGTH) ||
154 (sr.base[3] == DNS_DSDIGEST_SHA256 &&
155 sr.length < 4 + ISC_SHA256_DIGESTLENGTH))
163 if (sr.base[3] == DNS_DSDIGEST_SHA1)
164 sr.length = 4 + ISC_SHA1_DIGESTLENGTH;
165 else if (sr.base[3] == DNS_DSDIGEST_SHA256)
166 sr.length = 4 + ISC_SHA256_DIGESTLENGTH;
168 isc_buffer_forward(source, sr.length);
169 return (mem_tobuffer(target, sr.base, sr.length));
174 isc_region_t sr;
181 dns_rdata_toregion(rdata, &sr);
182 return (mem_tobuffer(target, sr.base, sr.length));