🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Article View: comp.sys.ibm.pc.misc
Article #402

Re: Suppress Booting by Ctrl-Alt-Delete

#402
From: Peter SPHINX Cellik
Date: Wed, 29 Jul 1992 08:21
84 lines
2592 bytes
In article <1992Jul28.071823.26750@Informatik.TU-Muenchen.DE>, listl@Informatik.TU-Muenchen.DE (Andreas Listl) writes:
|> 
|> Hello,
|> 
|> I am looking for a TSR-Program (TSR = Terminate and stay resident) which 
|> prevents the computer of beeing booted, if someone presses Ctrl-Alt-Delete.
|> A small C-Program would be fine.
|> 

How about a small C-- program:

/*
    Title:  NOBOOT.C--
    Description:  A small TSR program that disables the <CTRL><ALT><DEL> reboot.
    Run File Size:  254 bytes.
*/


?include "KEYCODES.H--"

word oldkeyhandle[2]={};
byte altflag=0,ctrlflag=0;

?define s_upctrl s_ctrl+128
?define s_upalt  s_alt+128


interrupt keyhandle ()
{
$ PUSH DS
$ PUSH AX
DS = CS;
$ IN AL,KEYBOARD_PORT
IF( AL == s_alt )
    altflag = 1;
ELSE IF( AL == s_ctrl )
    ctrlflag = 1;
ELSE IF( AL == s_upalt )
    altflag = 0;
ELSE IF( AL == s_upctrl )
    altflag = 1;
ELSE IF( AL == s_del )
    IF( ctrlflag == 1 )
        IF( altflag == 1 )
            {@ EATKEY();
            @ EOI();
            $ POP AX
            $ POP DS
            return();
            }
$ POP AX
$ POP DS
$ JMP FAR CSWORD[#oldkeyhandle]
}


main ()
{
@ WRITESTR("NOBOOT installed.  <CTRL><ALT><DEL> is now disabled.\n");
@ GETINTVECT(#oldkeyhandle,KEYBOARD_INT);
@ SETINTVECT( ,KEYBOARD_INT,CS,#keyhandle);
@ KEEP( , , ,#main);
}

/* end of NOBOOT.C-- */


C-- is a low level language that is a mix between C and 8086+ assembly.
C-- is currently Pre-Beta, and the Pre-Beta version is currently available
as FreeWare.  Since it is still Pre-Beta, it is not widely distributed as
yet.  I can send you a ZIP of it if you wish, that is if we work out a way
to get the ZIP to you.

I don't know how large the resident code is of the TSR, but my guess is
under 220 bytes, not too bad.

        SPHINX


====================================================
=== Kill others only if you wish to be killed.   ===
===                                       SPHINX ===   
====================================================
Technical Details
Message-ID: <1992Jul29.092129@axion.bt.co.uk>
Path: arc1-ca.pugleaf.net!sparky!uunet!mcsun!uknet!axion!pcellik
References: <1992Jul28.071823.26750@Informatik.TU-Muenchen.DE>

Show Full Headers
Complete Article Headers
Path: arc1-ca.pugleaf.net!sparky!uunet!mcsun!uknet!axion!pcellik
From: pcellik@axion.bt.co.uk (Peter SPHINX Cellik)
Newsgroups: comp.sys.ibm.pc.misc
Subject: Re: Suppress Booting by Ctrl-Alt-Delete
Keywords: Booting, Ctrl-Alt-Delete
Message-ID: <1992Jul29.092129@axion.bt.co.uk>
Date: 29 Jul 92 08:21:29 GMT
References: <1992Jul28.071823.26750@Informatik.TU-Muenchen.DE>
Sender: news@axion.bt.co.uk
Reply-To: pcellik@axion.bt.co.uk (Peter SPHINX Cellik)
Organization: British Telecom Research Labs
Lines: 84