HP3000-L Archives

September 1999, Week 4

HP3000-L@RAVEN.UTC.EDU

Options: Use Monospaced Font
Show Text Part by Default
Show All Mail Headers

Message: [<< First] [< Prev] [Next >] [Last >>]
Topic: [<< First] [< Prev] [Next >] [Last >>]
Author: [<< First] [< Prev] [Next >] [Last >>]

Print Reply
Subject:
From:
Barry Lake <[log in to unmask]>
Reply To:
Barry Lake <[log in to unmask]>
Date:
Thu, 23 Sep 1999 13:04:38 -0700
Content-Type:
text/plain
Parts/Attachments:
text/plain (34 lines)
At 3:02 PM -0400 9/23/99, [log in to unmask] wrote:
>Why not initiate a :WHILE loop looking for a secret password and prompting
>with a colon.  This would require a valid password to be entered or a break.
>A simple break might be too easy.
>
>SETVAR A " "
>WHILE A <> "12345"
>  INPUT A;PROMPT=":"
>ENDWHILE

I would amend this as follows:

  parm a="12345"
  option nobreak
  setvar b " "
  while b <> "!a"
     input b;prompt="!hpprompt"
  endwhile


1) The parm allows you to have a default lockword that's hard coded, but
you can change it by supplying your own at run time.
2) Option nobreak prevents anyone from breaking out of it.
3) The console prompt isn't guaranteed to be ":", so dereferencing hpprompt
sets it to whatever it happens to be.

Please be aware, however, that although this command file will lock all
access to any CI command, it still cannot prevent either CTRL-A or CTRL-B.


Barry Lake                                 [log in to unmask]
Allegro Consultants, Inc.                  www.allegro.com
(408)252-2330

ATOM RSS1 RSS2