I don't know...

This is a discussion on I don't know... within the C++ Programming forums, part of the General Programming Boards category; I know this doesnt go here, or maybe it does but anyway... I would like to make a program in ...

  1. #1
    Registered User
    Join Date
    Mar 2008
    Posts
    34

    I don't know...

    I know this doesnt go here, or maybe it does but anyway...

    I would like to make a program in C++ or Visual Basic 6.0, I just want to know how to do this: Make any folder have a password, then with the same program take that password off.

    Please help.

  2. #2
    Internet Superhero
    Join Date
    Sep 2006
    Location
    Denmark
    Posts
    964
    Quote Originally Posted by Houssen View Post
    I know this doesnt go here, or maybe it does but anyway...

    I would like to make a program in C++ or Visual Basic 6.0, I just want to know how to do this: Make any folder have a password, then with the same program take that password off.

    Please help.
    If you want help with VB then you are at the wrong place. But regarding C++ (I'm assuming here, that your platform is Windows?), you first need to learn all the basics, and then pick up on the win32 API. But my guess is that encrypting and decrypting a folder is a very non-trivial task, if you don't know any programming at the moment, don't expect to be able to do this within the next year, at the very least!
    How I need a drink, alcoholic in nature, after the heavy lectures involving quantum mechanics.

  3. #3
    Kernel hacker
    Join Date
    Jul 2007
    Location
    Farncombe, Surrey, England
    Posts
    15,677
    To JUST have a password on a directory is not possible. You can tell Windows (NT onwards?) to protect data in files or folders, here's a link:
    http://www.computerhope.com/issues/ch000705.htm

    However, that's not quite what you are asking for. I think the only solution for that would be a driver + service, which is absolutely not a simple task - it involves file-system drivers, which in itself is quite a complex matter, and to provide appropriate security without holes is not likely to be viable for someone who hasn't spent a lot of time as a programmer (at system programming level).

    --
    Mats
    Compilers can produce warnings - make the compiler programmers happy: Use them!
    Please don't PM me for help - and no, I don't do help over instant messengers.

  4. #4
    Registered User
    Join Date
    Mar 2008
    Posts
    34
    Lol, no, I just want to encrypt the folder, I know that it can be done in VB6, but I have no idea.

  5. #5
    Internet Superhero
    Join Date
    Sep 2006
    Location
    Denmark
    Posts
    964
    Quote Originally Posted by Houssen View Post
    Lol, no, I just want to encrypt the folder, I know that it can be done in VB6, but I have no idea.
    If you want to do it in VB, i suggest you use an up-to-date version rather than VB6, and then i think you should repost the question on the tech-board, since this forum is C++only. But don't expect to much, most people at this board are C/C++ programmers, not VB. Maybe you should find a VB Board and ask them instead?
    How I need a drink, alcoholic in nature, after the heavy lectures involving quantum mechanics.

  6. #6
    Kernel hacker
    Join Date
    Jul 2007
    Location
    Farncombe, Surrey, England
    Posts
    15,677
    Quote Originally Posted by Houssen View Post
    Lol, no, I just want to encrypt the folder, I know that it can be done in VB6, but I have no idea.
    It is not "done" in VB6 - it is done by NTFS which is the filesystem. VB6 may be able to ENABLE it to be encrypted, but it is not VB6 that is encrypting it. And no, I don't know how you go about setting this up in VB6 or C++.

    Actually, a quick search turned up this: http://www.codeproject.com/KB/security/SetDACLs.aspx

    No, that's not C++, but I'm pretty sure the C++ API is similar enough to quickly be able to look things up, should you have sufficient knowledge and skill to perform development the rest of the program. If you don't understand a think of the above link, then you probably should learn some basics first.

    --
    Mats
    Compilers can produce warnings - make the compiler programmers happy: Use them!
    Please don't PM me for help - and no, I don't do help over instant messengers.

  7. #7
    C++まいる!Cをこわせ! Elysia's Avatar
    Join Date
    Oct 2007
    Posts
    22,604
    It's certainly possible - especially with a shell extension.
    HOW it's done, is beyond my knowledge, however.
    But as far as I know, there have been solutions to do this without the need of any service or kernel code.
    Quote Originally Posted by Adak View Post
    io.h certainly IS included in some modern compilers. It is no longer part of the standard for C, but it is nevertheless, included in the very latest Pelles C versions.
    Quote Originally Posted by Salem View Post
    You mean it's included as a crutch to help ancient programmers limp along without them having to relearn too much.

    Outside of your DOS world, your header file is meaningless.

  8. #8
    Kernel hacker
    Join Date
    Jul 2007
    Location
    Farncombe, Surrey, England
    Posts
    15,677
    Quote Originally Posted by Elysia View Post
    It's certainly possible - especially with a shell extension.
    HOW it's done, is beyond my knowledge, however.
    But as far as I know, there have been solutions to do this without the need of any service or kernel code.
    Do you mean "ask for a password on this folder without using NTFS file protection", that works reliably and is not trivially bypassed by opening a command prompt or writing a tiny application?

    --
    Mats
    Compilers can produce warnings - make the compiler programmers happy: Use them!
    Please don't PM me for help - and no, I don't do help over instant messengers.

  9. #9
    C++まいる!Cをこわせ! Elysia's Avatar
    Join Date
    Oct 2007
    Posts
    22,604
    Oh yes, of course. You may write all sorts of complexity, but then you would need a API hook or driver to guard against everything.
    But to protect just explorer - a shell extension could be used.
    Quote Originally Posted by Adak View Post
    io.h certainly IS included in some modern compilers. It is no longer part of the standard for C, but it is nevertheless, included in the very latest Pelles C versions.
    Quote Originally Posted by Salem View Post
    You mean it's included as a crutch to help ancient programmers limp along without them having to relearn too much.

    Outside of your DOS world, your header file is meaningless.

Popular pages Recent additions subscribe to a feed

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21