mirror of
https://github.com/Kicksecure/security-misc.git
synced 2025-06-19 16:44:06 -04:00
set "shopt -s nullglob" to avoid failing when folder /etc/hide-hardware-info.d
does not exist or is empty
This commit is contained in:
parent
b05663c5f6
commit
cfbd77040a
1 changed files with 4 additions and 0 deletions
|
@ -6,12 +6,16 @@
|
||||||
sysfs_whitelist=1
|
sysfs_whitelist=1
|
||||||
cpuinfo_whitelist=1
|
cpuinfo_whitelist=1
|
||||||
|
|
||||||
|
shopt -s nullglob
|
||||||
|
|
||||||
## Allows for disabling the whitelist.
|
## Allows for disabling the whitelist.
|
||||||
for i in /etc/hide-hardware-info.d/*.conf
|
for i in /etc/hide-hardware-info.d/*.conf
|
||||||
do
|
do
|
||||||
source "${i}"
|
source "${i}"
|
||||||
done
|
done
|
||||||
|
|
||||||
|
exit
|
||||||
|
|
||||||
create_whitelist() {
|
create_whitelist() {
|
||||||
if [ "${1}" = "sysfs" ]; then
|
if [ "${1}" = "sysfs" ]; then
|
||||||
whitelist_path="/sys"
|
whitelist_path="/sys"
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue