diff options
author | trevor <trevor@FreeBSD.org> | 2000-10-22 23:36:25 +0800 |
---|---|---|
committer | trevor <trevor@FreeBSD.org> | 2000-10-22 23:36:25 +0800 |
commit | 0a09d8a073d881061fcadfe47d18092611caeaa6 (patch) | |
tree | b1a9a1810993fce2de1318814ca8c699c5a13bab /security/vlock/files | |
parent | 2a890c4fd8b9c360d70f5a72a7cd3b9776a5d41f (diff) | |
download | freebsd-ports-gnome-0a09d8a073d881061fcadfe47d18092611caeaa6.tar.gz freebsd-ports-gnome-0a09d8a073d881061fcadfe47d18092611caeaa6.tar.zst freebsd-ports-gnome-0a09d8a073d881061fcadfe47d18092611caeaa6.zip |
new port of vlock 1.3, a utility to lock a console until a password
is entered
PR: 21834
Submitted by: George Reid <services@nevernet.net>
Diffstat (limited to 'security/vlock/files')
-rw-r--r-- | security/vlock/files/patch-aa | 36 | ||||
-rw-r--r-- | security/vlock/files/patch-ab | 11 | ||||
-rw-r--r-- | security/vlock/files/patch-ac | 11 | ||||
-rw-r--r-- | security/vlock/files/patch-ad | 46 | ||||
-rw-r--r-- | security/vlock/files/patch-ae | 11 |
5 files changed, 115 insertions, 0 deletions
diff --git a/security/vlock/files/patch-aa b/security/vlock/files/patch-aa new file mode 100644 index 000000000000..506bc528bf29 --- /dev/null +++ b/security/vlock/files/patch-aa @@ -0,0 +1,36 @@ +--- Makefile.orig Sun Oct 8 18:03:19 2000 ++++ Makefile Sun Oct 8 18:03:24 2000 +@@ -1,24 +1,19 @@ + # vlock makefile + +-CC = gcc +-# remove the -DUSE_PAM, -ldl, and -lpam if you aren't using PAM +-RPM_OPT_FLAGS=-O2 +-CFLAGS = $(RPM_OPT_FLAGS) -DUSE_PAM +-LDFLAGS = -ldl -lpam -lpam_misc ++CFLAGS += -DUSE_PAM ++LDFLAGS = -lpam + + OBJS = vlock.o signals.o help.o terminal.o input.o + +-vlock: $(OBJS) ++all: vlock + +-vlock.man: vlock.1 +- groff -man -Tascii vlock.1 > vlock.man ++vlock: $(OBJS) ++ cc $(OBJS) $(LDFLAGS) -o vlock + +-vlock.o: vlock.h version.h +-signals.o: vlock.h +-help.o: vlock.h +-terminal.o: vlock.h +-input.o: vlock.h ++install: ++ /usr/bin/install -c -s -o root -g wheel -m 4555 vlock /usr/local/bin/vlock ++ /usr/bin/install -c -o root -g wheel -m 444 vlock.1 /usr/local/man/man1 + + clean: +- rm -f $(OBJS) vlock core core.vlock ++ rm -f $(OBJS) vlock vlock.core + diff --git a/security/vlock/files/patch-ab b/security/vlock/files/patch-ab new file mode 100644 index 000000000000..cf1153881467 --- /dev/null +++ b/security/vlock/files/patch-ab @@ -0,0 +1,11 @@ +--- signals.c.orig Sun Oct 8 18:03:19 2000 ++++ signals.c Sun Oct 8 18:03:24 2000 +@@ -16,7 +16,7 @@ + #include <signal.h> + #include <sys/wait.h> + #include <sys/ioctl.h> +-#include <sys/vt.h> ++#include <sys/consio.h> + #include "vlock.h" + + diff --git a/security/vlock/files/patch-ac b/security/vlock/files/patch-ac new file mode 100644 index 000000000000..bf65297f651e --- /dev/null +++ b/security/vlock/files/patch-ac @@ -0,0 +1,11 @@ +--- terminal.c.orig Sun Oct 8 18:03:19 2000 ++++ terminal.c Sun Oct 8 18:03:24 2000 +@@ -15,7 +15,7 @@ + #include <unistd.h> + #include <termios.h> + #include <sys/ioctl.h> +-#include <sys/vt.h> ++#include <sys/consio.h> + #include "vlock.h" + + diff --git a/security/vlock/files/patch-ad b/security/vlock/files/patch-ad new file mode 100644 index 000000000000..bcd6e35fbc3e --- /dev/null +++ b/security/vlock/files/patch-ad @@ -0,0 +1,46 @@ +--- vlock.c.orig Sun Oct 8 18:03:19 2000 ++++ vlock.c Sun Oct 8 18:03:24 2000 +@@ -14,12 +14,10 @@ + #include <stdio.h> + #include <unistd.h> + #include <fcntl.h> +-#include <getopt.h> + #include <termios.h> + #include <signal.h> +-#include <sys/vt.h> +-#include <sys/kd.h> + #include <sys/ioctl.h> ++#include <sys/consio.h> + #include "vlock.h" + #include "version.h" + +@@ -37,20 +35,12 @@ + + int main(int argc, char **argv) { + +- static struct option long_options[] = { /* For parsing long arguments */ +- {"current", 0, &o_lock_all, 0}, +- {"all", 0, &o_lock_all, 1}, +- {"version", no_argument, 0, O_VERSION}, +- {"help", no_argument, 0, O_HELP}, +- {0, 0, 0, 0}, +- }; + int option_index; /* Unused */ + int c; + struct vt_mode vtm; + + /* First we parse all the command line arguments */ +- while ((c = getopt_long(argc, argv, "acvh", +- long_options, &option_index)) != -1) { ++ while ((c = getopt(argc, argv, "acvh")) != -1) { + switch(c) { + case 'c': + o_lock_all = 0; +@@ -107,6 +97,7 @@ + vtm.mode = VT_PROCESS; + vtm.relsig = SIGUSR1; /* handled by release_vt() */ + vtm.acqsig = SIGUSR2; /* handled by acquire_vt() */ ++ vtm.frsig = SIGUSR1; /* needed by FreeBSD */ + ioctl(vfd, VT_SETMODE, &vtm); + } + diff --git a/security/vlock/files/patch-ae b/security/vlock/files/patch-ae new file mode 100644 index 000000000000..8a040468317d --- /dev/null +++ b/security/vlock/files/patch-ae @@ -0,0 +1,11 @@ +--- input.c.orig Wed Jan 13 16:19:14 1999 ++++ input.c Sun Oct 22 08:22:42 2000 +@@ -291,7 +291,7 @@ + setuid(getuid()); + setgid(getgid()); + +- sprintf(prompt, "%s's password: ", username); ++ snprintf(prompt, 99, "%s's password: ", username); + #endif /* !USE_PAM */ + } + |