security/keyprint: Add OPIE support to fix functionality
Since the opieprint port has been removed, and since the S/Key utilities are no longer included with FreeBSD, it makes sense to patch this port to make it functional once again - and there is nothing gained by leaving it unusable. PR: 32936, 71089, 219177 Submitted by: crahman@gmail.com
This commit is contained in:
parent
e574252494
commit
3c6c4b3bee
Notes:
svn2git
2021-03-31 03:12:20 +00:00
svn path=/head/; revision=477723
3 changed files with 36 additions and 1 deletions
|
@ -3,7 +3,7 @@
|
|||
|
||||
PORTNAME= keyprint
|
||||
PORTVERSION= 1.0
|
||||
PORTREVISION= 1
|
||||
PORTREVISION= 2
|
||||
CATEGORIES= security
|
||||
MASTER_SITES= LOCAL/mharo
|
||||
|
||||
|
|
10
security/keyprint/files/patch-keyblank.ps
Normal file
10
security/keyprint/files/patch-keyblank.ps
Normal file
|
@ -0,0 +1,10 @@
|
|||
--- keyblank.ps.orig 1999-05-23 14:49:31.000000000 -0600
|
||||
+++ keyblank.ps 2017-05-09 15:38:11.013636000 -0600
|
||||
@@ -1087,6 +1087,7 @@ end
|
||||
(74:) 183.85 460.14 T
|
||||
(99:) 302.65 460.14 T
|
||||
(75:) 183.85 454.04 T
|
||||
+(100:) 302.65 454.04 T
|
||||
178.85 761.24 178.85 608.99 2 L
|
||||
V
|
||||
0.25 H
|
25
security/keyprint/files/patch-keyprint
Normal file
25
security/keyprint/files/patch-keyprint
Normal file
|
@ -0,0 +1,25 @@
|
|||
--- keyprint.orig 2017-05-09 16:34:33.966382000 -0600
|
||||
+++ keyprint 2017-05-09 16:34:57.987755000 -0600
|
||||
@@ -10,18 +10,14 @@ $|=1;
|
||||
|
||||
@ENV{'PATH'}='/usr/bin';
|
||||
|
||||
-$username=$ARGV[0] || `whoami`;
|
||||
-$username =~ /(\w+)/;
|
||||
-$username = $1;
|
||||
-
|
||||
-open(NAMES, "$dir/keyinfo $username|")
|
||||
- || die "can't run keyinfo: $!, stopped";
|
||||
+open(NAMES, "$dir/opieinfo|")
|
||||
+ || die "can't run opieinfo: $!, stopped";
|
||||
$key = <NAMES>;
|
||||
$key =~ /^\d+\s+(\w+)/
|
||||
- || die "User $username not found. Make sure you have run keyinit, stopped";
|
||||
+ || die "Keys not found. Make sure you have run opiepasswd, stopped";
|
||||
$key = $1;
|
||||
close(NAMES);
|
||||
-open(KEYS, "$dir/key -n 99 99 $key|")
|
||||
+open(KEYS, "$dir/opiekey -n 100 100 $key|")
|
||||
|| die "can't open $keyfile: $!, stopped";
|
||||
open(PS, "<$psfile") || die "can't open $psfile: $!, stopped";
|
||||
|
Loading…
Reference in a new issue