Technical Documentation Knowledge Base Help Docs Troubleshooting Handbooks Support Docs User Guides English
Changing Routers Passwords on Teleport
On this Page:
- Actions Required
- Prerequisites
- Creating Passwords for Stores’ Routers on LastPass
- Accessing a Server
- Setting SREs SSH RSA Keys
- Bonus: Setting Server’s Time
Actions Required
- Create passwords and sections for servers on LastPass
- Access servers and change routers passwords
- Add SREs’ SSH RSA keys to the routers authorized keys
- Set server time
Prerequisites
- Having a LastPass user
- Having a Teleport User
- Having Teleport installed
- Having necessary SSH RSA Keys
- Knowing which servers to make changes to.
Creating Passwords for Stores’ Routers on LastPass
To create a section for each store’s router password on LastPass:
-
Access DoxHut’s LastPass Password Manager panel.
-
Create a New Item by clicking the plus icon located at the bottom right corner. This action will open a modal where you must fill in a few fields.
-
Fill in the Name field with the server’s name.
-
Fill in the Folder field with the “Shared-stores” value.
-
Fill in the Username with “root.”
-
Create a strong password (use the LastPass’ Generate Secure Password tool).
-
Copy the password and paste it into the Site Password field.
-
Save this configuration by clicking Save.
-
Repeat the whole process for each of the servers listed below.
Accessing a Server
To access a server:
-
List the existing servers by running:
tsh ls
You will see all servers listed as shown next
-
Select a server and access it:
tsh ssh doxhut@doxhut-2-xavier-0
(example) -
Then, access the router:
ssh root@192.168.1.1
-
Once in the router, change its password by running:
passwd
-
You will get a confirmation message and that’s it!
Setting SREs SSH RSA Keys
To set an SREs SSH RSA key in the router:
-
Run:
cd /root
-
List all directories:
ls -hal
-
Open .ssh
cd .ssh
-
Then, edit the authorized keys
vim authorized_keys
-
Once on the Vim editor, press “i” to activate the editor mode.
-
Paste one of the SSH RSA keys.
-
Press “Esc” to exit edit mode.
-
Press “o” to jump into the next line.
-
Press “i” to activate the editor mode and paste a second key.
-
Repeat the process for key you must insert in the file.
-
Finally, make sure you are not in the editor mode, and press “:wq” to save changes and quit.
Bonus: Setting Server’s Time
Since you are already on the server, use the chance to set the server’s time by running:
uci set system.ntp.enable_server='1' ; uci commit system ; /etc/init.d/sysntpd restart
💡 Note: You will not get any confirmation message for the last step.