What are the challenges you face when working across database platforms? Take the survey
Options

square brackets not allowed in encryption password

nmalaneynmalaney Posts: 3
edited January 18, 2007 10:01PM in SQL Backup Previous Versions
Sorry if this has been reported before - I did a few searches on the forum website and did not see any related postings.

In SQL Backup (we are currently running 4.6.0.815), I found that if you use a square bracket (]) in the encryption password for the backup file, you get one of the following 2 errors when trying to perform a restore:

1) If the square bracket appears in the middle of the encryption password (example: te]st ), you get the following error (after clicking "Restore" on the final screen of the Restore Wizard) when you try to peform a restore of the backup file with this password: "Syntax error 'st" after 'te'.

2) If the square bracket appears at the end of the encryption password (example: test]), you get the following error (after clicking "Restore" on the final screen of the Restore Wizard) when you try to perform a restore of the backup file with this password on the file screen of the Restore Wizard: "Error 710: Wrong password entered".

The strange this is that on Screen 2 of the Restore Wizard, it accepts the password containing the square bracket when you click the "Set" button.


My question is this: Are there other special characters that I should avoid when creating encryption passwords

Comments

  • Options
    peteypetey Posts: 2,358 New member
    That is indeed a bug. The GUI should prevent the entry of the square brackets.

    Other characters to avoid:
    - the opening square bracket ([)
    - the single quote character (')
    Peter Yeoh
    SQL Backup Consultant Developer
    Associate, Yohz Software
    Beyond compression - SQL Backup goodies under the hood, updated for version 8
  • Options
    Thanks for the quick response. This is a somewhat nasty bug :( because a user could encrypt a backup with a password w/o realizing that they will be unable to restore (and decrypt) that backup file at a later date.
  • Options
    peteypetey Posts: 2,358 New member
    Yes, they would be unable to restore using the GUI.

    They can still perform by restore by running the extended stored procedure directly e.g.

    for the first case (te]st])
    master..sqlbackup '-sql "RESTORE DATABASE pubs FROM DISk = [e:\backups\pubs\pubs.sqb] with password = [te]st]"'
    

    for the second case (test])
    master..sqlbackup '-sql "RESTORE DATABASE pubs FROM DISk = [e:\backups\pubs\pubs.sqb] with password = [test]]"'
    
    Peter Yeoh
    SQL Backup Consultant Developer
    Associate, Yohz Software
    Beyond compression - SQL Backup goodies under the hood, updated for version 8
Sign In or Register to comment.