• Home
  • History
  • Annotate
  • Raw
  • Download
  • only in /freebsd-13-stable/contrib/ntp/lib/isc/win32/

Lines Matching refs:source

49 get_from_filesource(isc_entropysource_t *source, isc_uint32_t desired) {
50 isc_entropy_t *ent = source->ent;
52 HCRYPTPROV hcryptprov = source->sources.file.handle;
56 if (source->bad)
66 source->bad = ISC_TRUE;
80 * Poll each source, trying to get data from it to stuff into the entropy
89 isc_entropysource_t *source;
143 * Poll each file source to see if we can read anything useful from
157 source = ent->nextsource;
159 * Remember the first source so we can break if we have looped back to
162 firstsource = source;
172 if (source->type == ENTROPY_SOURCETYPE_FILE)
173 got = get_from_filesource(source, remaining);
179 source = ISC_LIST_NEXT(source, link);
180 if (source == NULL)
181 source = ISC_LIST_HEAD(ent->sources);
183 ent->nextsource = source;
197 * check to see if we have a callback source. If so, call them.
199 source = ISC_LIST_HEAD(ent->sources);
200 while ((remaining != 0) && (source != NULL)) {
205 if (source->type == ENTROPY_SOURCETYPE_CALLBACK)
206 got = get_from_callback(source, remaining, blocking);
214 source = ISC_LIST_NEXT(source, link);
230 destroyfilesource(isc_entropyfilesource_t *source) {
231 CryptReleaseContext(source->handle, 0);
235 destroyusocketsource(isc_entropyusocketsource_t *source) {
236 UNUSED(source);
243 isc_entropysource_t *source;
253 source = NULL;
266 source = isc_mem_get(ent->mctx, sizeof(isc_entropysource_t));
267 if (source == NULL) {
275 source->magic = SOURCE_MAGIC;
276 source->type = ENTROPY_SOURCETYPE_FILE;
277 source->ent = ent;
278 source->total = 0;
279 source->bad = ISC_FALSE;
280 memset(source->name, 0, sizeof(source->name));
281 ISC_LINK_INIT(source, link);
282 source->sources.file.handle = hcryptprov;
287 ISC_LIST_APPEND(ent->sources, source, link);
297 if (source != NULL)
298 isc_mem_put(ent->mctx, source, sizeof(isc_entropysource_t));