taskSavane - Tasks: task #1159, add ### at the end of the register...

 
 
Show feedback again

You are not allowed to post comments on this tracker with your current authentification level.

task #1159: add ### at the end of the register keys if missing

Submitted by:  Mathieu Roy <yeupou>
Submitted on:  Thu 13 Jan 2005 09:12:43 AM UTC  
 
Should Start On: Sun 09 Jan 2005 11:00:00 PM UTCShould be Finished on: Sun 09 Jan 2005 11:00:00 PM UTC
Category: BackendStatus: Done
Priority: 1 - LaterPlanned Release: 
Assigned to: Sylvain Beucler <beuc>Open/Closed: Closed
Privacy: PublicFor/By: None

(Jump to the original submission Jump to the original submission)

Sat 15 Jan 2005 11:00:54 AM UTC, comment #7:

Instead of s/\'/\'\'/g, would not it be s/\'/\\\'/g ?

If you think it is best in SetUserSettings, go for it. But, then, you should add it in most Set*Settings for consistency.

Mathieu Roy <yeupou>
Project Administrator
Sat 15 Jan 2005 10:42:15 AM UTC, comment #6:

Ping? :)

Sylvain Beucler <beuc>
Project AdministratorIn charge of this item.
Thu 13 Jan 2005 04:40:00 PM UTC, comment #5:

It's not really at the DBI level:
sub SetUserSettings {
SetDBSettings("user", "user_name='$_[0]'", "$_[1]='$_[2]'");
}

if arg0 or arg2 contains a quote, then there will be a quote mismatch.

As far as I see, we just need to add s/\'/\'\'/g in SetUserSettings-like procedures. That's how it's done in sv_skills, despite sv_skills directly uses the 'mysql' command.

Sylvain Beucler <beuc>
Project AdministratorIn charge of this item.
Thu 13 Jan 2005 04:18:18 PM UTC, comment #4:

Theorically perl DBI by itself escape characters when needed. Are you sure that adding a script to escape character wont alter content in any way? Why in this case the escaping made by perl DBI isn't reliable - no way to fix that?

Mathieu Roy <yeupou>
Project Administrator
Thu 13 Jan 2005 03:22:32 PM UTC, comment #3:

Aie aie sir.

There is a small issue to discuss: at a point I have to escape an argument that I pass to SetUserSettings, so that if the key contains a <<'>>, it doesn't make the SQL query fail.

I think this test should be moved in SetUserSettings itself.

Is it ok?

The script was applied to the Savannah database. We haven't received complaints yet.

Sylvain Beucler <beuc>
Project AdministratorIn charge of this item.
Thu 13 Jan 2005 03:02:19 PM UTC, comment #2:

If it works (I guess it does), feel free to add it in update/1.0.6 + close this item.

Regards,

Mathieu Roy <yeupou>
Project Administrator
Thu 13 Jan 2005 02:10:59 PM UTC, comment #1:

Here's the script, feel free to edit.

Sylvain Beucler <beuc>
Project AdministratorIn charge of this item.
Thu 13 Jan 2005 09:12:43 AM UTC, original submission:

And update script should be provided for 1.0.6 that would add ### if missing, at the end of registered ssh keys, for keys registered a long time ago with the Savane version that was not always adding it.

Mathieu Roy <yeupou>
Project Administrator

 

Attached Files
file #275:  update_authorized_keys.pl added by beuc (2kB - application/octet-stream)

 

Depends on the following items: None found

Items that depend on this one

Digest:
   task dependencies.

 

Carbon-Copy List
  • -unavailable- added by beuc (Updated the item)
  • -unavailable- added by yeupou (Submitted the item)
  •  

    Do you think this task is very important?
    If so, you can click here to add your encouragement to it.
    This task has 0 encouragements so far.

    Only logged-in users can vote.

     

    Please enter the title of George Orwell's famous dystopian book (it's a date):

     

     

    Follow 17 latest changes.

    Date Changed By Updated Field Previous Value => Replaced By
    Wed 23 Feb 2005 10:53:31 PM UTCbeucAssigned toNone=>beuc
      Open/ClosedOpen=>Closed
    Thu 17 Feb 2005 09:19:56 PM UTCbeucStatusNone=>Done
    Sat 15 Jan 2005 11:00:54 AM UTCyeupouShould Start OnMon 10 Jan 2005 12:00:00 AM UTC=>Sun 09 Jan 2005 11:00:00 PM UTC
      Should be Finished onMon 10 Jan 2005 12:00:00 AM UTC=>Sun 09 Jan 2005 11:00:00 PM UTC
    Thu 13 Jan 2005 04:40:00 PM UTCbeucShould Start OnMon 10 Jan 2005 11:00:00 PM UTC=>Mon 10 Jan 2005 12:00:00 AM UTC
      Should be Finished onMon 10 Jan 2005 11:00:00 PM UTC=>Mon 10 Jan 2005 12:00:00 AM UTC
    Thu 13 Jan 2005 04:18:18 PM UTCyeupouShould Start OnTue 11 Jan 2005 12:00:00 AM UTC=>Mon 10 Jan 2005 11:00:00 PM UTC
      Should be Finished onTue 11 Jan 2005 12:00:00 AM UTC=>Mon 10 Jan 2005 11:00:00 PM UTC
    Thu 13 Jan 2005 03:22:32 PM UTCbeucShould Start OnTue 11 Jan 2005 11:00:00 PM UTC=>Tue 11 Jan 2005 12:00:00 AM UTC
      Should be Finished onTue 11 Jan 2005 11:00:00 PM UTC=>Tue 11 Jan 2005 12:00:00 AM UTC
    Thu 13 Jan 2005 03:02:19 PM UTCyeupouShould Start OnWed 12 Jan 2005 12:00:00 AM UTC=>Tue 11 Jan 2005 11:00:00 PM UTC
      Should be Finished onWed 12 Jan 2005 12:00:00 AM UTC=>Tue 11 Jan 2005 11:00:00 PM UTC
    Thu 13 Jan 2005 02:10:59 PM UTCbeucShould Start OnWed 12 Jan 2005 11:00:00 PM UTC=>Wed 12 Jan 2005 12:00:00 AM UTC
      Should be Finished onWed 12 Jan 2005 11:00:00 PM UTC=>Wed 12 Jan 2005 12:00:00 AM UTC
      Attached File-=>Added update_authorized_keys.pl, #32
    Thu 13 Jan 2005 09:13:01 AM UTCyeupouDependencies-=>task #1088 is dependent
    Show feedback again

    Back to the top


    Powered by Savane 3.1-cleanup