473,387 Members | 1,504 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,387 software developers and data experts.

Shell Integration

dfound
52
hi, Can anyone give me links to tutorials on shell integration.I am making a program to encrypt files in BC++ and I need it to show up option to encrypt and decrypt when I right-click on a file(or folder). Can anyone please give me those links. Also please give me the links to tutorial on making a file shredder because I want to know how it works. :-)
Feb 24 '07 #1
10 2244
sicarie
4,677 Expert Mod 4TB
hi, Can anyone give me links to tutorials on shell integration.I am making a program to encrypt files in BC++ and I need it to show up option to encrypt and decrypt when I right-click on a file(or folder). Can anyone please give me those links. Also please give me the links to tutorial on making a file shredder because I want to know how it works. :-)
Not too sure how to make stuff show up in the right-click menu, but for a file shredder, it really depends on how secure you are talking. If you want DoD standard, the algorithm is to write random data across the disk at least six times before wiping with a NaN value (not a number) - or some value across the entire disk. Write random digits to memory. That's what it is.

The trick with file shredders is to make sure there is no residual charge from the original disk. Most US government agencies will (depending on the level of classification) overwrite the data, burn the hard drives to ash, and then store the ash for a set period of time to make sure the data is GONE.
Feb 24 '07 #2
dfound
52
Well, I have a doubt. Instead of writing random data, can't I just truncate the file.
And by the way,does writing on the hard disk mean over writing the file itself...
Or is there any way to really write on the hard disk. :-)
Feb 25 '07 #3
sicarie
4,677 Expert Mod 4TB
Well, I have a doubt. Instead of writing random data, can't I just truncate the file.
Truncate means shorten, so the data would still be at the beginning of the space in memory where the file resides - there would still be information there. If you don't care about a forensics analyst coming in and working on the computer, you can just delete it and empty your recycle bins and tmp folders - that'll keep 99% of people from finding it.
And by the way,does writing on the hard disk mean over writing the file itself...
Or is there any way to really write on the hard disk. :-)
Buffer memory, such as the Knoppix and Ubunut live CDs, can keep a program and basic OS while the hard drive is being formatted/overwritten. The Linux BBC (bootable business card) requires only - I think - 32mb to have a full command-line interface with several hundred programs, network support, disk-shredder...
Feb 25 '07 #4
dfound
52
Well, Does it mean that I have to over write the file again and again , and then
delete it. I have created a program hat would read a file and over write it in some random manner. So if I the delete it using the "unlink" command, will it act as
a file shredder???
Feb 25 '07 #5
sicarie
4,677 Expert Mod 4TB
Well, Does it mean that I have to over write the file again and again , and then
delete it. I have created a program hat would read a file and over write it in some random manner. So if I the delete it using the "unlink" command, will it act as
a file shredder???
That depends on how secure you want to make it. It has been proven possible to recover traces of magnetic charge on hard drives. This means that you can write something, then overwrite it, and still recover what was on there initially. It's possible, though extremely difficult.

The trick is to wipe the memory locations. Just because you write data to a file doesn't mean that its going to overwrite another copy, in fact, if you write as much, or more random data to a file, even if it's named the same thing, your OS is probably going to create a new file, and just remove the pointer to the old, letting that memory space be empty until it finds something it can put in there. Deleting and writing data to a file through Windows is not 100% secure...
Feb 26 '07 #6
dfound
52
Then can you please tell me how to write over in the memory location. I have no idea about it. It will be very useful if you please give me some links to the same..
:-)
Feb 26 '07 #7
sicarie
4,677 Expert Mod 4TB
Then can you please tell me how to write over in the memory location. I have no idea about it. It will be very useful if you please give me some links to the same..
:-)
I have never done something like that - so I don't know any good links for you (though I imagine a google search would be the place to start), I personally just used one of the available *nix tools to overwrite my entire hard drive.

Does anyone else know a good way to go about this?
Feb 26 '07 #8
dfound
52
Thanks for your replies.I will try Google search.
Feb 27 '07 #9
sicarie
4,677 Expert Mod 4TB
Thanks for your replies.I will try Google search.
It's definitely an interesting project - you could try to open a file and try to do something with the first character of it - get the memory location that way, and then start overwriting however much memory as the file is large. The problem will be if there are any pesky operating system end blocks or nodes, that might be overwritten, or if the file is not contiguous (I don't know enough about OS memory management to know how likely that is...).

Anyway, good luck and let me know what you find out - I'm very curious!
Feb 27 '07 #10
dfound
52
Hi, the only thing I could dig up from some examples was that those programs only overwrites the file.There is nothing to be seen about those memory spaces.
Do you think the following program would work as a shredder.

Expand|Select|Wrap|Line Numbers
  1. #include<fstream.h>
  2. #include<dos.h>
  3. #include<string.h>
  4. int main()
  5. {
  6. long ctr=0;
  7. ifstream fin("testfile.txt",ios::in|ios::binary);
  8. ofstream fout("testfile.txt",ios::out|ios::ate|ios::nocreate|ios::binary);
  9. char buf[32768];
  10. if(!fin||!fout)
  11. return 0;
  12. while(!fin.eof())
  13. {                                                         //ANOTHER METHOD    
  14. fin.seekg(ctr*32768);                             //fin.seekg(ctr);
  15. fin.read((char*)&buf,strlen(buf));              //fin.get(ch);
  16. for(long i=0;i<strlen(buf);i++)                  //ch='0';
  17. buf[i]='0';                                          
  18. fout.seekp(ctr*32768);                           //fout.seekp(ctr);
  19. fout.write((char*)&buf,strlen(buf));           //fout.put(ch);
  20. ctr++;
  21. }
  22. fin.close();
  23. fout.close();
  24. unlink("testfile.txt");
  25. return 0;
  26. }
The program does overwrite the contents and then deletes it.
Feb 28 '07 #11

Sign in to post your reply or Sign up for a free account.

Similar topics

2
by: Jorgen Grahn | last post by:
I couldn't think of a good solution, and it's hard to Google for... I write python command-line programs under Win2k, and I use the bash shell from Cygwin. I cannot use Cygwin's python package...
3
by: Tomas | last post by:
Hi! I'm looking for a replacement for the standard interactive python shell. So far I've tried IPython and PyCrust. I liked both, but I'm not 100% happy with any of them. My main complaint about...
0
by: miles__ahead | last post by:
Hi. I like to create little utilities for Windows. It's nice to have Shell Integration, such as using the Context Menu. I've googled but haven't seen any Python example code for IContextMenu...
0
by: Stylus Studio | last post by:
DataDirect XQuery(TM) is the First Embeddable Component for XQuery That is Modeled after the XQuery API for Java(TM) (XQJ) BEDFORD, Mass.--Sept. 20, 2005--DataDirect Technologies...
2
by: Sin | last post by:
Hello everyone, I'm totally stumped at how little info I can find in MSDN or on the web concerning this. It's almost as if only microsoft personel hold the key to these secrets or something!!! ...
3
by: Chris Dunaway | last post by:
When you double click on a .zip file in a default Windows XP installation, it opens a folder view of the .zip archive and it appears to be well integrated into the OS. In other words, it looks and...
8
by: Pieter | last post by:
Hi, I want for my application a Windows Shell Integration (for example like TortoiseSVN: http://tortoisesvn.tigris.org/), but i can't find anything about it?? What I basicly wnat is to be...
1
by: YellowfinTeam | last post by:
Marketplace: Yellowfin reporting 3.1 with BIRT Integration Yellowfin is proud to announce the release of 3.1. The major theme of this release is enhanced integration capability. We have...
1
by: Vitank | last post by:
What i'm trying to accomplish, is to create a custom shell integration that would allow me to pass the file path of the file to that got right-click to a website's <input id="file_name"...
0
by: taylorcarr | last post by:
A Canon printer is a smart device known for being advanced, efficient, and reliable. It is designed for home, office, and hybrid workspace use and can also be used for a variety of purposes. However,...
0
by: ryjfgjl | last post by:
If we have dozens or hundreds of excel to import into the database, if we use the excel import function provided by database editors such as navicat, it will be extremely tedious and time-consuming...
0
by: ryjfgjl | last post by:
In our work, we often receive Excel tables with data in the same format. If we want to analyze these data, it can be difficult to analyze them because the data is spread across multiple Excel files...
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.