This is a read-only snapshot of the ComputerCraft forums, taken in April 2020.
ChaddJackson12's profile picture

IDLock (Floppy Disk Password System)

Started by ChaddJackson12, 11 October 2012 - 11:27 PM
ChaddJackson12 #1
Posted 12 October 2012 - 01:27 AM
IDLock
Current Version: 1.0

IDLock is a ComputerCraft Security System, But With Cards!

IDLock has a few features, and has many more to come. This is also an application which requires that HTTP is enabled to work. If you do not know how to enable HTTP, there is a tutorial under How To Install This Program. Tell me what you think, and what I could add or improve on. Enjoy!

Program Features:
Spoiler- Has configurable output side for correct authentication.
- Has an option to play a noteblock on alternate side for correct authentication.
- Multi-User Support.
- Easy Key Interactions.
- Automatic Updater.

Planned Features:
Spoiler- Ability To Input Username & Password Without Card.
- Ability To Have Multi-User Configurable Output Side. (2 Users = 2 Output Sides)
- Improve Updater.
- Improve Overall Code
- Improve Security

Important Information:
Spoiler- The ID Card is a floppy disk.
- There is not a fix for deleting the only user.
- If you delete the only user, you cannot uninstall the program, or recreate it.
- The updater forces updates, and they're not optional, as of yet. (If I need to change it then let me know.)
- HTTP has to be enabled or the program cannot be installed, or update.
- Please report any bugs that you find.
- Please suggest anything that you think should be added.
- Don't reupload this program, or its code, as it isn't yours to reupload.
- Don't change the code, as it isn't your code.
- Don't take credit for the code, because it isn't yours.

Key Interactions (Very Important)
SpoilerThe Key Interactions Are Used For Interacting With The Computer, And Are Not Visible Ingame.
Insert - Prompts To Add Another User.
Delete - Prompts To Delete User. (Don't delete the only user, there is not a fix for this yet, and it will cause BIG problems.)
End - Prompts To Uninstall Program. (Any registered user as of yet; can uninstall the program, so be aware.)

How To Install This Program:
SpoilerMake sure HTTP is enabled, or this will not work!
1. Go to a computer.
2. Insert a floppy disk in the disk drive connected to the computer.
3. On the computer, type: pastebin get RTygjhrP startup
4. Restart the computer.

How to enable HTTP:
Spoiler1. Go to the root directory of the game, .minecraft/.techniclauncher
2. Make sure that you are in the folder that contains the Saves, Bin, ect…
3. In that folder, open the Config folder.
4. Find the file that is for computercraft. Mod_Computercraft
5. Open it and change enableAPI_http=0 to enableAPI_http=1
6. Save the file, and you're done! You may need to reboot the game though!

Changelog
V1.0
SpoilerFirst Release Of The Program!

- Added configurable output side for correct authentication.
- Added an option to play a noteblock on alternate side for correct authentication.
- Added Multi-User Support.
- Added Easy Key Interactions.
- Added Automatic Updater.

Code:
Spoiler

term.clear()
term.setCursorPos(1,1)
print("IDLock V1.0n")
print("HTTP Must Be Enabled For Possible Installation.")
print("Would You Like To Install IDLock? Y | N")
repeat
event, key = os.pullEvent("key")
os.sleep(0.1)
until key == 21 or key == 49
if key == 21 then
textutils.slowPrint("nDownloading Installer...")
os.sleep(1)
local DownloadInstaller = http.get("http://dl.dropbox.com/u/39147094/IDLock/Installer")
f = fs.open("Installer", "w")
f.write(DownloadInstaller.readAll())
f.close()
print("nLaunching Installer")
shell.run("Installer")
elseif key == 49 then
print("nInstallation Cancelled!")
os.sleep(1)
fs.delete("startup")
os.reboot()
end
ChaddJackson12 #2
Posted 12 October 2012 - 01:40 AM
COLORFUL! I like that, most people dont give a damn about their posts anymore and just say "here, take it or leave it: pastebin get <code> <file>"
:3 this appears to be one of your first programs (because this is usually most peoples first program)
Quick suggestion: Pastebin that installer so we can quickly download the downloader to download more things!
and also, if you put code in make sure to surround it with the Code tag… :P/>/>

Screenshots! ;)/>/> I request screenies!
Alright, when I can, I will post screenshots. I will also surround my code in tags because I forgot that.

I pastebined the code that will give you the option to install it, then if you want to; it downloads the installer to install the rest of the programs.

This is my 3rd submitted program, and I made it more interactive than the average card lock.
Apothecarian #3
Posted 21 October 2012 - 01:34 AM
Thank you for this. It is running smashingly.
ChaddJackson12 #4
Posted 21 October 2012 - 01:54 AM
Thank you for this. It is running smashingly.
Awesome, nice to hear that it is working so well.. :)/>/>
TheEvilSocks #5
Posted 21 October 2012 - 03:34 PM
Im on a server and the owner doesn't want to enable httpAPI, how can I install this?
ChaddJackson12 #6
Posted 21 October 2012 - 04:07 PM
Im on a server and the owner doesn't want to enable httpAPI, how can I install this?
You can't. But I could probably make a version that doesn't need HTTP. (But you would have to type a whole bunch.)
MrZuribachi #7
Posted 21 October 2012 - 08:56 PM
Nice one. I didn't even know that HTTP is possible at all oô Haha :)/>/>
ChaddJackson12 #8
Posted 21 October 2012 - 09:45 PM
Nice one. I didn't even know that HTTP is possible at all oô Haha :)/>/>
Neither did I until I saw a post that had Pastebin on it for the download. :)/>/>
MrZuribachi #9
Posted 22 October 2012 - 05:51 PM
Well the HTTP-API makes things WAAAY easier and more convenient. No longer copying the code, putting into an editor, saving, deletein the .txt-extension, including into the CC-Folder etc etc etc … :)/>/>
ChaddJackson12 #10
Posted 22 October 2012 - 10:46 PM
Well the HTTP-API makes things WAAAY easier and more convenient. No longer copying the code, putting into an editor, saving, deletein the .txt-extension, including into the CC-Folder etc etc etc … :)/>/>
Yeah, and not only that but if you are on a server you don't have to type a whole bunch of code.
TheEvilSocks #11
Posted 01 March 2013 - 11:56 AM
Could you add a feature to allow us to log everything via rednet? that would be very useful!
ChaddJackson12 #12
Posted 01 March 2013 - 03:16 PM
Could you add a feature to allow us to log everything via rednet? that would be very useful!
Perhaps, in a future update.. I've taken a break from ComputerCraft Coding for a while…