hxping7 / wl500g

Automatically exported from code.google.com/p/wl500g
0 stars 0 forks source link

WebUI: Cannot store several ssh public keys #384

Open GoogleCodeExporter opened 9 years ago

GoogleCodeExporter commented 9 years ago
What steps will reproduce the problem?
1. Open router settings, go to System Setup - Services
2. Add 3 or more 2048 bit rsa public keys
3. Press Apply or Finish

What is the expected output? What do you see instead?
I expect settings getting saved. Instead I see an error page, because httpd 
crashes.

What version of the product are you using?
RT-N10U 1.9.2.7-rtn-r4772

Original issue reported on code.google.com by burning....@gmail.com on 11 Feb 2013 at 4:36

Attachments:

GoogleCodeExporter commented 9 years ago
An old httpd should be enhanced to accept several keys. As usual, patches are 
welcome.

Original comment by lly.dev on 16 Feb 2013 at 10:52

GoogleCodeExporter commented 9 years ago
Use System Setup - System Command page

Backup /usr/local/root/.ssh/authorized_keys
cp /usr/local/root/.ssh/authorized_keys 
/usr/local/root/.ssh/authorized_keys.save

Add keys "incremently"
echo -n ssh-rsa AAAAAAABBBBBBBBCCCCCC>>/usr/local/root/.ssh/authorized_keys
...
echo -n DDDDDDDDEEEEEEEEEFFFFFFF >>/usr/local/root/.ssh/authorized_keys
echo user@host>>/usr/local/root/.ssh/authorized_keys

Check result
cat /usr/local/root/.ssh/authorized_keys

Restore previouse version if result is not as expected
cp /usr/local/root/.ssh/authorized_keys.save 
/usr/local/root/.ssh/authorized_keys

... or use ssh with new keys and first of all
flashfs save
flashfs commit
to save your changes (or make some changes in web and save all)

Original comment by grey....@gmail.com on 18 Jan 2014 at 8:27