From: mdw Date: Fri, 20 Feb 1998 18:12:35 +0000 (+0000) Subject: Make the `become' program setuid root when installing. X-Git-Tag: 1.3.3~54 X-Git-Url: https://git.distorted.org.uk/~mdw/become/commitdiff_plain/5b175cbbd74099aca651346b7ee9a8034f249217 Make the `become' program setuid root when installing. --- diff --git a/src/Makefile.am b/src/Makefile.am index 31e95ae..effb91c 100644 --- a/src/Makefile.am +++ b/src/Makefile.am @@ -1,7 +1,7 @@ ## Process this file with `automake' to generate `Makefile.in' ## -*-makefile-*- ## -## $Id: Makefile.am,v 1.8 1998/01/12 16:45:36 mdw Exp $ +## $Id: Makefile.am,v 1.9 1998/02/20 18:12:35 mdw Exp $ ## ## Makefile for `become' ## @@ -29,6 +29,9 @@ ##----- Revision history ---------------------------------------------------- ## ## $Log: Makefile.am,v $ +## Revision 1.9 1998/02/20 18:12:35 mdw +## Make the `become' program setuid root when installing. +## ## Revision 1.8 1998/01/12 16:45:36 mdw ## Fix copyright date. ## @@ -113,6 +116,17 @@ keygen_SOURCES = keygen.c become_DEPENDENCIES = libbcm.a keygen_DEPENDENCIES = libbcm.a +##----- Become must be setuid root ------------------------------------------ + +install-data-hook: + become_prog=${bindir}/`echo become|sed '${transform}'`; \ + { chown root $${become_prog} && \ + chmod 4755 $${become_prog}; } || \ + { echo ">>>>>"; \ + echo ">>>>> $${become_prog} must be installed setuid-root"; \ + echo ">>>>>"; \ + } + ##----- Testing ------------------------------------------------------------- ## --- The test programs ---