using computercraft for secured base entry

  • Please make sure you are posting in the correct place. Server ads go here and modpack bugs go here
  • The FTB Forum is now read-only, and is here as an archive. To participate in our community discussions, please join our Discord! https://ftb.team/discord

Azurl

New Member
Jul 29, 2019
172
0
0
Hi!

I want to make an password protected entry into my base. I don't need any programming help, I just need to know if there is any way to make the computercraft computer secure from tampering. Can I lock access out by interacting with a monitor instead of the computer directly?
 

RoodSquirrel

New Member
Jul 29, 2019
8
0
0
I found some code online for a password protected door, this code basically has hack prevention stopping users to be able to mess with the program, the only way the door can be opened it through the correct password. Not sure if that's what you're looking for? If it is I can always link you though.
 

Azurl

New Member
Jul 29, 2019
172
0
0
nah, I have a program in mind with a list of passwords it randomly cycles through. what I need is a way to prevent users from terminating the program and look inside the computer for the password file, or look in the program itself
 

RoodSquirrel

New Member
Jul 29, 2019
8
0
0
Yeah thought you was looking for something different but asked just in case, can't help you with what you need sadly, good luck with finding it though:p
 

EPfencer

New Member
Jul 29, 2019
35
0
0
there's a tutorial on the computer craft wiki, which says that if you ad
os.pullEvent = os.pullEventRaw
to the top of your program, people shouldn't be able to terminate the lock and get in using another command
 

casilleroatr

New Member
Jul 29, 2019
1,360
0
0
os.pullEventRaw is what you need to prevent ctrl+t

If you have an advanced computer and monitor you can make interactive monitors. At the core of any computer craft button is the "monitor_touch" event (You should check to make sure that is what it is called). When fired it will return the x and y position that you right click the monitor on. Therefore you can make buttons. I would recommend that you set the text scale to 0.5 for this though.

Finally, if you are particularly concerned about people being able to see the password list you can host the list on a remote computer and have password clients dotted around your base without having to distribute your list. The modem api gives you everything you need to work that out.
 

Bomb Bloke

New Member
Jul 29, 2019
612
0
0
Note that if you place a disk drive next to any CC computer, and put a disk with a "startup" file on it in the drive, then the computer will boot from that file on its next startup. Say they put an empty startup file on the disk, that means it simply boots to the command line prompt, giving them full access to do whatever they want with the system.

The only way to prevent someone from rebooting your computer (Ctrl+R) is to block their character's physical access to it.

Hence I'd recommend rigging something up involving wireless modems. The terminals the players CAN access sends off what they type to a hidden computer that 1) has the password list and 2) has the ability to open the door.

You can alternatively do what you were originally thinking - rig up a monitor for them to interact with - though since they can't "type" into a monitor this means that you'll have to manually code "buttons" for players to push on that monitor yourself, which is more work. It also means you need a hole in your wall for the cable, which players could potentially navigate a turtle through. Come to think of it, it'd be pretty easy to have a turtle dig along cables until it finds a computer, then take its place and start pulsing redstone signals at random - would be a good "skellington key" or sorts for such doors.
 

VikeStep

New Member
Jul 29, 2019
1,117
0
0
a neat workaround for the disk drive problem with people overriding startup is to get an OpenPeripherals remote. it lets you type stuff into the computer using a remote device. just make sure you don't lose it! This means you can place the computer underneath the ground away from sight

to connect it you need to shift right click the remote on the computer
 
Last edited:

casilleroatr

New Member
Jul 29, 2019
1,360
0
0
the clear() function also works on monitors. Say you wrapped the monitor to the variable monitor you could clear the monitor by coding monitor.clear()