News:

MASM32 SDK Description, downloads and other helpful links
MASM32.com New Forum Link
masmforum WebSite

My educational system

Started by TNick, September 19, 2006, 12:15:48 PM

Previous topic - Next topic

TNick

Here is the project that I wroted for graduating the nursery school in ASM.
As I will pass another classes, this topic will contain the projects written for that. Feel free to PM me or to post here your opinions, bugs, ...

This project (Blind Crypt) is intended only for testing. Do not use it with important files, because it may turn them to garbage. The size will be preserved,though. :bdg

[EDIT] Full package now aviable in the next post[/EDIT]

PBrennick

QuoteThe size will be preserved,though.

That is too funny (and it has happened to me).
Paul
The GeneSys Project is available from:
The Repository or My crappy website

TNick

Hope nothing important was there, Paul!

I'm still working at that source code. Until then any ideea will be highly appreciated (except "Forget about ASM and start make poetry" :bg

TNick

#3
Finally, here is the source code and the exe file.

I'm still working on it, mainly on testing, so your replies will be highly appreciated, along with some infos about your system.

The source was written using RadASM V 2.2.0.8 (the project file is in there) and MASM32.

So, tell me, did I graduate the kindergarten?


For everyone who downloaded the package till 27.09.06: SORRY! There were some mistakes during the translation of source code and during coding. Everything seems to work OK now.


BLIND CRYPT  - Brief description



   Blind Crypt is a program wich encrypt and decrypt files on your local machine. Main difference between other programs with the same purpose and this one is that Blind Crypt will destroy the file if your password is wrong, when decoding, turning it to garbage.
There will be no previous or subsequently message concearning this. The password is not stored anywhere and, after typeing, is not compared against anything.
   Reductively, this program is not intended to be used for general needs of encoding, but for sensitive files, wich shouldn't be accesed by anyone but you, and if someone try to do that, should be destroyed.

   Blind Crypt groups files in projects. A project file contains the number of files that belong here, the version of program that has generated that file, a list of files (with full path and name), a status for each file (encoded or decoded) and eventually, the path and name for the mask file. Only one project can be loaded in the program at a given time.

   As you launch the program, main window appears, but most of it's elements are disabled.To start using it, go to <Project> menu and choose <New Project> or <Open Project>.

Creating a new project
   To create a new empty project, go to <Project> menu and choose <New Project>. A dialog box appears to let you specify a path and a name for the project file. You can use standard .bcp (blind crypt project) extension or any other, or you can type a name without an extension, the program will try to create a file with exactly the name you type.
   As soon as you choose the file name and location and hit OK, you are prompted to enter a password for this project. It must have at least four characters and not more than 128. Be VERY carefully about this password, because, when you reopen this project, if you enter a wrong one, the project file will be destroyed and you won't be able ANYMORE to decode containing files. Enter the password in the first box and retype it in the second. You can toogle between mask and normal characters using the check box in the bottom left corner.
   When you are done, press OK or hit ENTER.

Opening an existing project
   To open an existing project, go to <Project> menu and choose <Open Project>. Use the dialog box to navigate and choose the project, then press Open. You are requested to enter the password for this project. Be VERY carefully about this password, because, if you enter a wrong one, the project file will be destroyed and you won't be able ANYMORE to decode containing files.
   When you are done, press OK or hit ENTER. The only list in the window will now show you all the files in this project.
   
Adding files to a project
   Ant any time, when you have an opened project, the ADD button in the bottom left corner of the window will be enabled. It allows you to add files to this project. Press this button and you will see a dialog box you can use to find the files you want. You can select multiple files in here. Once you mak your selection and hit Open, files are added to project's list. Before this, each name is compared against project's path and name, all real files and mask files. If a match is found, the file will not be added.

Deleting files from a project
   To delete files just select them in list and press the DEL button in the bottom left side of the window. Files will be removed only if they are decoded.
   
Selection
   There are 3 buttons concearning selection in the bottom left side of the panel: SEL ALL (selects all items in the list), INV SEL (invert selection in the list) and MUL SEL (toogle between two possible modes: single selection and multiple selection). If you select just one item (in single or multiple selection mode), the two edit boxes in the higher right corner inform you about the real file name and path and, if there is a mask file, about it's name and path.

File(s) status
   In the right side you have two buttons that infom about and change the status (encoded or decoded) of the selected items. If all items in the selection are encoded, then the ENCODE button will be pressed and the DECODE button unpressed. If all is decoded, the situation changes. If the status is not the same both buttons will be rised. You can use this two buttons to encode or decode any number of files at once. As soon as you press one of this buttons a panel is shown, informing you about the current file that is processed and that the program isn't stuck. Here you can cancel the process, but the processing of the current file won't be stopped.

Mask File
   You can create/choose a file to store the original file in encoded mode. This is a mask file. If a item doesn't have a mask file, it will be encoded under his original path and name. If all items ia a selection have a mask file, then the ADD button in MASK section will be pushed and the DEL button in the same section will be rised. If everyone have a mask, the situation is oposite, andif some have and some have not, both buttons will be rised.
   To add a mask file to an item, select that item and press the ADD button in the MASK section. You will see a dialog that let's you to browse for a folder and to choose a name. Once you hit Save, the file will be added as mask file for selected item, unless that file exists and is already in the project, or that path and name was already used for another item's mask file.
   If you have selected more that one item at the time you hit ADD, another dialog appears. Here you can choose a pattern for names that will be used as mask file names, and you can choose wether to store all those masks in a folder or in the same folder as the original file. To create all mask files in the same directory as the original file, just check the box in the middle. To use a unique directory for all selected items, uncheck that box and type the path or use the <...> button in the left of the first edit box and choose one.
   Next, type a pattern in the second edit box (the one at th bottom), using the ? character as placeholder. No default extension will be added at the end of a name. You can use one to eight "?" characters, wich will be replaced with hexadecial numbers. Example: My mask (?? ??).msk -> first file will be named "My mask (00 00).msk", second one "Mymask (00 01).msk", tenth one "My mask (00 0A).msk" , ....
   When you have choosen all this, hit OK, or cancel if you have second thoughts.
   To remove mask file from it's item(s) press the DEL button in the MASK section. You can remove a mask only if that item is decoded.

Password
   In the right side of the window, under the STATUS and MASK sections, is the PASSWORD section, wich groups four buttons.
   As you create the project, you enter a password that will be used to encode-decode all the files it (will) contain. To encrease the protection, you can add to each item a own password. This will be used WITH the project password to generate output, and it's highly recomended to use this option.
   To add a password to a item, use the ADD button in the PASSWORD section. The dialog is similar to the one that appears when you create a new project. To remove the password from an item use the DEL button. Note that you can't remove a password from an encoded item.
   Once you add a password, it will reside in memory until you close the project or you delete the password or you hit the REMOVE butt on (removes the password from memory, but the file still needs a password to be managed). When you load a project or if you just have used the REMOVE button, you can use the ENTER button to store the password in memory for items that do have a password.


Best protection
   When you use this program to protect your private files, best protection will be achived if you take care about following aspects:
- use a long password (at least 64 characters, best is 128). There is a direct relationship between your password's lenght and the protection that will result.
- do not use repetitive sequence of characters in passwords - there will be no improvement in protection.
- use the PASSWORD feature for each file. There will be a HIGH  improvement in protection.
- use the MASK feature. If someone wants to see your files, he/she must first find those files.
- do not store your encoded file in the same path as the file. Instead, hide it somewhere and don't worry - you don't have to remember the path everytime you acces it; <mask file> does that for you.


Conspiracy Theory
   There are some things you should know before you put your secrets in here
1. This program can (and will) be modified so that the mechanism of encoding to be avoided. In this case any password you use, any mask you choose, your files will be exposed.
2. Your keyboard can (and will) be traced to find out the passwords




TO BE CONTINUED ...


[attachment deleted by admin]

PBrennick

There are serious problems with this program.  After some stumbling trying to figure out what the heck I was supposed to do I created a folder called Blind and copied 3 files to it.  I then selected that folder as my project and then figured out by trial and error that I need some sort of pattern file, I created pattern.txt and put Jennifer? as the string in that file.  But the Add function still does not work, it complains that there is no <?> in the file so I gave up as I cannot go any further.  You need to simplify this process or explain somewhere what the heck do you want.  I entered 3 files, a password and a pattern.  Shouldn't it work now?

Paul
The GeneSys Project is available from:
The Repository or My crappy website

TNick

Paul,

It was my mistake not to write and include documentation with the program. Sorry!
Thanks for your interest! Now you have a ReadMe in the ZIP and there i have explained there how it works.


Nick

PBrennick

areadme file is not going to get the ADD function to work, methinks. I think I will pass on this one.

Paul
The GeneSys Project is available from:
The Repository or My crappy website