9fans - fans of the OS Plan 9 from Bell Labs
 help / color / mirror / Atom feed
* [9fans] ipso(1) patch
@ 2004-03-14 13:54 Nils M Holm
  2004-03-14 15:25 ` David Tolpin
  2004-03-14 16:07 ` David Presotto
  0 siblings, 2 replies; 7+ messages in thread
From: Nils M Holm @ 2004-03-14 13:54 UTC (permalink / raw)
  To: 9fans


I just put my passwords in a secstore and got the following message
when running ipso:

can't dial tcp!$auth!5356
secstore authentication failed
secstore read failed - bad password?

After adding '-s $auth' to the auth/secstore invocation in /rc/bin/ipso,
everything works fine. However, I guess that ipso is supposed to run
fine without this modification. Am I missing something?

Anyway, while looking at ipso, I thought that an option to just fetch
the factotum keys without displaying them would be nice. So I added the
'-q' flag which does this.

BTW, is there any common format for supplying patches for Plan 9?
I guess that using diff(1) would cause trouble when patching an
already-patched file, since it uses absolute line numbers.

Below, there is a context diff containing my changes to ipso, in
case anyone is interested.

Nils.

----- ipso(1) -q cdiff -----
*** ipso.old	Sun Mar 14 14:31:31 2004
--- ipso	Sun Mar 14 14:34:36 2004
***************
*** 11,16 ****
--- 11,17 ----
  name = secstore
  get = secstoreget
  put = secstoreput
+ edit = yes
  
  fn secstoreget{
  	auth/secstore -i -g $1 <_password
***************
*** 50,57 ****
  		name = aescbc
  		get = aesget
  		put = aesput
  	case *
! 		echo >[2=1] 'usage: ipso [-s] [file ...]'
  		exit usage
  	}
  	shift
--- 51,60 ----
  		name = aescbc
  		get = aesget
  		put = aesput
+ 	case -q
+ 		edit = no
  	case *
! 		echo >[2=1] 'usage: ipso [-aqs] [file ...]'
  		exit usage
  	}
  	shift
***************
*** 68,74 ****
  bind -c /tmp /srv
  cd /tmp
  
! echo '
  	Warning: The editor will display the secret contents of
  	your '$name' files in the clear.
  '
--- 71,77 ----
  bind -c /tmp /srv
  cd /tmp
  
! if (~ $edit yes) echo '
  	Warning: The editor will display the secret contents of
  	your '$name' files in the clear.
  '
***************
*** 103,109 ****
  sleep 2; date > _timestamp	# so we can find which files have been edited.
  
  # edit the files
! $editor `{for(i in $files) basename $i}
  
  # copy the files back
  for(i in `{editedfiles}){
--- 106,113 ----
  sleep 2; date > _timestamp	# so we can find which files have been edited.
  
  # edit the files
! if (~ $edit yes) $editor `{for(i in $files) basename $i}
! if not if (~ factotum $files) read -m < factotum > /mnt/factotum/ctl
  
  # copy the files back
  for(i in `{editedfiles}){
-- 
Nils M Holm <nmh@t3x.org> -- http://www.t3x.org/nmh/


^ permalink raw reply	[flat|nested] 7+ messages in thread

end of thread, other threads:[~2004-03-15  7:29 UTC | newest]

Thread overview: 7+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2004-03-14 13:54 [9fans] ipso(1) patch Nils M Holm
2004-03-14 15:25 ` David Tolpin
2004-03-14 15:36   ` David Presotto
2004-03-14 18:55     ` boyd, rounin
2004-03-14 18:54   ` boyd, rounin
2004-03-14 16:07 ` David Presotto
2004-03-15  7:29   ` Nils M Holm

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).