BREAK

Prev Next Home Home Table Of Contents Index

BREAK.SYS - Keeps users in Batch Files

Download:
BREAK.ZIP

This little goody keeps people from breaking out of batch files. It works great for zero-K menu systems like MarxMenu.

Unlike all the other similar programs this one is smart. It only traps CTRL-C if you are in COMMAND.COM, but allows your applications to see CTRL-C. It only uses about 400 bytes of RAM.

To install BREAK.SYS, simply add this line to your CONFIG.SYS file:


 DEVICE=BREAK.SYS

If you're using BREAK.SYS with QEMM or other memory manager, load the memory manager first in your CONFIG.SYS file.

BREAK.SYS can be enabled or disabled by using the BREAK ON and BREAK OFF commands either from the command line or from batch files.

Advanced Features:

Although BREAK.SYS is better than DOS, it isn't perfect. There are still situations where you can break out of batch files. If it is important to not break out then you can use it as follows:


 DEVICE=BREAK.SYS /C

Using it this way the CTRL-C key is disabled completely. Your application software will NOT be able to utilize CTRL-C.

BREAK.SYS has another switch, /T that works like /C except that once you execute BREAK ON it returns to smart CTRL-C handling. The idea here is that more often you need bullet-proof protection while the system is booting up, but after going to the main menu you can switch to smart protection. At the end of your bootup batch files add the lines:


 BREAK ON
 BREAK OFF

This will switch BREAK.SYS into smart mode checking.

Another trick to help keep people from breaking out to the command line is setting the shell statement in the CONFIG.SYS file as follows:


 SHELL=COMMAND.COM /E:400 /C AUTOEXEC.BAT

With this command, any user who improperly exits a batch file will have his/her computer lock-up (stop functioning, requiring a reboot). In some cases, this is better than letting the user get access to the command line.

BREAK.SYS has another feature that makes BREAK ON work better. If you use it like this:


 DEVICE=BREAK.SYS /B

Then when you run BREAK ON and the users presses [CTRL-\] it will break you out of programs you might otherwise be stuck in. This feature is great for software developers to use when testing code.

Prev Next Home Home Table Of Contents Index

Sponsors
Shopping
Forum
Forum
email
EMail
Index
Index
Home
Home