nss_mc_initgr.c revision 225dc6914cdc8920b02a129b98ece1ed97b99c03
0N/A * System Security Services Daemon. NSS client interface 0N/A * Lukas Slebodnik <lslebodn@redhat.com> 180N/A * Copyright (C) 2015 Red Hat 51N/A * This program is free software; you can redistribute it and/or modify 51N/A * it under the terms of the GNU Lesser General Public License as 180N/A * published by the Free Software Foundation; either version 2.1 of the 180N/A * License, or (at your option) any later version. 180N/A * This program is distributed in the hope that it will be useful, 180N/A * but WITHOUT ANY WARRANTY; without even the implied warranty of 0N/A * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 336N/A * GNU Lesser General Public License for more details. 336N/A * You should have received a copy of the GNU Lesser General Public License 336N/A/* INITGROUPs database NSS interface using mmap cache */ 208N/A /* additional checks before filling result*/ 216N/A /* entry is now invalid */ 253N/A /* check we have enough space in the buffer */ 3N/A /* Get max address of data table. */ 35N/A /* hashes are calculated including the NULL terminator */ 40N/A /* If slot is not within the bounds of mmaped region and 66N/A * it's value is not MC_INVALID_VAL, then the cache is 66N/A * probbably corrupted. */ 75N/A /* free record from previous iteration */ 22N/A /* check record matches what we are searching for */ 33N/A /* if name hash does not match we can skip this immediately */ 73N/A * - name_len cannot be longer than all strings or data 73N/A * - data->name cannot point outside strings 93N/A * - all data must be within data_table 93N/A * - name must be within data_table */