https://fedorahosted.org/freeipa/ticket/957

>From 20974e900dc062be3dbe527c2a6b7cddb7a0a641 Mon Sep 17 00:00:00 2001
From: Jakub Hrozek <jhro...@redhat.com>
Date: Sat, 12 Feb 2011 10:28:06 +0100
Subject: [PATCH 1/2] Make sure only root can run ipa-client-install

https://fedorahosted.org/freeipa/ticket/957

---
 ipa-client/ipa-install/ipa-client-install |    3 +++
 1 files changed, 3 insertions(+), 0 deletions(-)

diff --git a/ipa-client/ipa-install/ipa-client-install 
b/ipa-client/ipa-install/ipa-client-install
index a32564d..5012c65 100755
--- a/ipa-client/ipa-install/ipa-client-install
+++ b/ipa-client/ipa-install/ipa-client-install
@@ -810,6 +810,9 @@ def main():
 
 try:
     if __name__ == "__main__":
+        if not os.getegid() == 0:
+            sys.exit("\nYou must be root to run ipa-client-install.\n")
+
         sys.exit(main())
 except SystemExit, e:
     sys.exit(e)
-- 
1.7.4

_______________________________________________
Freeipa-devel mailing list
Freeipa-devel@redhat.com
https://www.redhat.com/mailman/listinfo/freeipa-devel

Reply via email to