Merge pull request #84 from Bandie/master

Bugfix for pam_panic_config, KDE resolves icon, GNOME3 doesn't
This commit is contained in:
Bandie 2018-11-03 11:21:25 +01:00 committed by GitHub
commit e8f9419b08
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
11 changed files with 25 additions and 9 deletions

1
.gitignore vendored
View File

@ -33,6 +33,7 @@ po/*.sin
src/pam_panic/man/*
!src/pam_panic/man/Makefile.am
!src/pam_panic/man/man8/
src/pam_panic_config/pam_panic_config
src/pam_panic_pw/pam_panic_pw
src/pam_panic_pw/man/*
!src/pam_panic_pw/man/Makefile.am

View File

@ -77,7 +77,9 @@ AC_CONFIG_FILES([
src/pam_panic_pw/man/Makefile
src/pam_panic_config/Makefile
src/pam_panic_config/applications/Makefile
src/pam_panic_config/icons/Makefile
src/pam_panic_config/icons/48x48/Makefile
src/pam_panic_config/icons/64x64/Makefile
src/pam_panic_config/icons/scalable/Makefile
test/Makefile
])

View File

@ -1,2 +1,8 @@
SUBDIRS = applications icons
SUBDIRS = applications icons/48x48 icons/64x64 icons/scalable
bin_SCRIPTS = pam_panic_config
%: %.prebuild
{ sldr=$$(echo "$(SECUREDIR)" | $(SED) 's/\//\\\//g'); $(SED) "s/__SECURELIBDIR__/$$sldr/" $< > $@ ; }
clean-local:
$(RM) *.tmp

View File

@ -18,7 +18,7 @@ Keywords[es]=PAM;seguridad;contraseña;autenticación;usb;
Keywords[jp]=PAM;;;;USB;
Exec=sudo pam_panic_config
TryExec=pam_panic_config
Icon=/usr/share/icons/hicolor/scalable/apps/pampanic.svg
Icon=pampanic
Terminal=true
Categories=Settings;Security;ConsoleOnly;
StartupNotify=false

View File

@ -0,0 +1,2 @@
appicondir=$(datadir)/icons/hicolor/48x48/apps
appicon_DATA=pampanic.png

Binary file not shown.

After

Width:  |  Height:  |  Size: 2.2 KiB

View File

@ -0,0 +1,2 @@
appicondir=$(datadir)/icons/hicolor/64x64/apps
appicon_DATA=pampanic.png

Binary file not shown.

After

Width:  |  Height:  |  Size: 3.5 KiB

View File

Before

Width:  |  Height:  |  Size: 1.8 MiB

After

Width:  |  Height:  |  Size: 1.8 MiB

View File

@ -8,6 +8,9 @@
CONFIGFILE="/etc/pam.d/pampanic"
LHBU="$HOME/LUKSHeaderBackup"
# Set on build time
SECUREDIR="__SECURELIBDIR__"
if [ $EUID -ne 0 ]; then
echo "Please run this script as root or using sudo."
exit 1
@ -230,7 +233,7 @@ power=$?
# Configuration generation
dialog --backtitle "pam_panic's Configuration Generator" \
--infobox "Generating configuration..." 3 40
config="#%PAM-1.0\nauth requisite pam_panic.so"
config="#%PAM-1.0\nauth requisite $SECUREDIR/pam_panic.so"
case $power in
"0")
@ -255,15 +258,15 @@ case $serious in
config="$config serious=$serious_dev"
;;
esac
config="$config\naccount requisite pam_panic.so"
config="$config\naccount requisite $SECUREDIR/pam_panic.so"
# Write config file
writeout=0
if [ -f $CONFIGFILE ]; then
ask "Configfile exist" "$CONFIGFILE exists. Overwrite it?"
ov=$?
case $ov in
writeout=$?
case $writeout in
"0")
echo -e "$config" > $CONFIGFILE
;;
@ -275,7 +278,7 @@ fi
# Finished message
clear
[ $ov -eq 0 ] && echo "Done! <3" || echo "Nothing done! </3"
[ $writeout -eq 0 ] && echo "Done! <3" || echo "Nothing done! </3"
echo -e "\n"
echo "What now?"