password on my table

can i put password on my table


Answer this question

password on my table

  • Sapna

    Hi,
    To protect VFP dbf, you may take a look at XITech Cryptor.

    http://www.xitech-europe.co.uk/Cryptor.html

  • ciaranh

    Years ago I've written a little routine that does something simmilar. Keep in mind that it wasn't done in a multi user environment. You may need to put some more thought into handeling this in M/U environment.

    -You use the low level io commands to open a table.
    - do an XOR operation to the first few bytes with some arbitarry key, or password. This basically corrupts the header.
    - Anytime you want to open the table, you have to do another XOR operation on the header, which then 'uncorrupts' the table.

    hope this helps :-)





  • Ofir Epstein

    Not really. You can do as Andy said, but doesn't buy you much security. It all depends on who are you defending against.

    A better solution might be encrypting your data. Either the whole table transparently with a product like Cryptor or some columns (like CC numbers, salary, SSN, etc.)

    For encryption, you can use the old Win CryptoAPI (now deprecated, but free and somewhat easy), or external routines like Craig Boyd's Encrypt / Decrypt functions for VFP.

    Or you could move your data (like many/most of us do) to SQL Server or similar DB that offers built-in security.

    See also:

    Security in FoxPro (protecting application and data) by Christof Wollenhaupt

    Fox Wiki

     


  • cablehead

    >> can i put password on my table

    Not directly, but if you are using VFP 7.0 or later you can enable DBC Events (see the Help File for details) and you can then use the DBC_BeforeOpenTables event. There are examples in Solution.APP that ships with all versions of VFP too that show how you can use this.

    However this will not someone opening the table with an application that by-passes VFP altogether (like a free downloadable DBF Editor/Viewer that anyone can get from the internet hackers).

    If you are still using VFP 6.0 there is no built-in security mechanism (those were just safer days I guess).

    What exactly is the issue you are trying to solve here



  • password on my table