7 Replies Latest reply on Feb 10, 2010 3:31 PM by kingphysh

    Password protect subforms

    jtbgolfer2003 Level 1

      I would like for the user to beable to open the form but hide some of the subforms unless they have a password.  Ex. I could open my form and fill out the first page.  Save the form and someone else could open the form and enter a password to view and edit the whole document.  Is this even possible with LiveCycle.

        • 1. Re: Password protect subforms
          Dallas Kuhn

          As far as i know, this is not possible.

          You can view all the password options in File > Form Properties > PDF

          Security.

          • 2. Re: Password protect subforms
            Niall O'Donovan Level 7

            Hi,

             

            It is possible, but involves a fair bit of scripting bringing together solutions from Paul Guerette (lock all fields) and Dimosthenis Theodoridis (article on Generating and working with hashes in dynamic PDF forms) and an AcroDialog (from Windjack solutions) to create a nice dialogue window to bring it all together to the user.

             

            Basic approach would be to have a function to lock the selected subforms/fields. Then declare global variables in the File / Form properties / Variables tab for usernames and/or passwords. Use Dimosthenis's solution to generate SHA-256 hash strings for each password and then this is what you use in the global variable. When  the user inputs their password, the script would first convert it to a SHA-256 hash string and compare it with the global variable, if it matches it would run an unlock fields function.

             

            Signing form (passwords).png

             

            It can be done, but it is involved - it just depends if it is worth the effort for your application.

             

            Good luck,

             

            Niall 

            • 3. Re: Password protect subforms
              Dallas Kuhn Level 3

              Thanks Niall. Good to know this is actually possible.

              Dallas

              • 4. Re: Password protect subforms
                kingphysh Level 4

                For what it is worth:

                 

                I regularly hide a subform that I call a "Control Panel". It allows administration of the form using AdobeReader--a user/admin with the right combination of arbitrary information entered into 3 fields already present on the form, can unlock (or reveal) the control panel. Once inside, there are tables to allow changes to product pricing, product descriptions, even administrate password info for a second admin. Also inside, there is a button to close it. Once closed and saved, the form is ready to be used with the updated information. Simple.

                 

                Granted, this may not offer the level of security needed. It isn't incrypted. However, there is asolutely no evidence that it exists, so it is unlikely to be subject to hacking efforts. And, for my needs, it is not critical that the security be absolutely, 100% bullet-proof. It is not widely distributed and the limited negative consequences of a breach don't merit extra efforts in securing it.

                 

                Stephen

                • 5. Re: Password protect subforms
                  Niall O'Donovan Level 7

                  Hi Stephen,

                   

                  I like it - nice, clean and easy to implement!!

                   

                  Niall

                  • 6. Re: Password protect subforms
                    jtbgolfer2003 Level 1

                    I like also but still don't understand exactly.  Would you care to explain a little more?  I am still new to scripting especially buttons.

                    • 7. Re: Password protect subforms
                      kingphysh Level 4

                      Here is an example. I can relate to being a beginner--not being a programmer myself.

                       

                      Follow the instructions on the form to reveal the "Secret Space". I don't know if this will help you, since it is not clear to me what you are attempting to conceal.

                       

                      If you want to conceal some of what the user has entered, you could have the "Subform" open when the form opens, and then when the user is done entering what needs to be hidden, click a button that hides the "Subform". Then only the Admin could reveal it again, by using the same technique demonstarted in the attached example.

                       

                      Hope this helps.

                       

                      Stephen