Тёмный

How to Reset Admin (root) Password on MySQL 

webpwnized
Подписаться 37 тыс.
Просмотров 86 тыс.
50% 1

Author: Jeremy Druin
Twitter: @webpwnized
Thank you for watching. Please help! Up vote, subscribe or even support this channel at / webpwnized (Click Support).
With access to the MySQL server, the MySQL root (administrator) password can be reset. The MySQL administrative user (aka root) stores its password hash in the mysql.user table (as does all MySQL users). By starting the MySQL server with skip grants option and using SQL queries to overwrite the MySQL root/admin password hash, the MySQL root/admin/administrator password can be changed to any value.
The MySQL instance demoed in the video is installed on Ubuntu Linux but the technique works on any Linux or Windows system because the technique interacts with the MySQL server itself. The Windows or Linux operating system is not important.
MySQL Server does not store passwords, but instead stores password hashes. When the user enters a password, the system hashes the password then compares the calculated password hash against the password hash on file in the MySQL user table. If the two password hashes match, the system authenticates the user. The root/admin user has more privileges than other users
The webpwnized RU-vid channel is dedicated to information security, security testing and ethical hacking. There is an emphasis on web application security but many other topics are covers. Some of these include forensics, network security, security testing tools and security testing processes. The channel provides videos to encourage software developers and system administrators to perform security testing. Also, the channel educates the next generation of security testers and bug bounty hunters who want to respectfully, legally and ethically help system owners that allow security testing.

Наука

Опубликовано:

 

7 янв 2017

Поделиться:

Ссылка:

Скачать:

Готовим ссылку...

Добавить в:

Мой плейлист
Посмотреть позже
Комментарии : 73   
@alexdlveliz2394
@alexdlveliz2394 5 лет назад
the only method that worked, after 20 different methods, you have my gratitude
@deanbell1969
@deanbell1969 5 лет назад
Tried many other vids before finding yours. YOU ROCK!!!!
@abdulkabir7527
@abdulkabir7527 4 года назад
It says '/var/run/mysqld' for UNIX socket file dont exists
@Itsrichayo
@Itsrichayo 4 года назад
Wow. I learned quite a lot but I left more confused than I was with all the password issues. I think I will simply use my windows machine for SQL related projects. Thanks again.
@OswaldoGoite
@OswaldoGoite 5 лет назад
This helped me a lot, thank you very much.
@Jameskaguo
@Jameskaguo 4 года назад
this is the only solution worked for me among thousands, be blessed
@robsonmvieira
@robsonmvieira 6 лет назад
Amazing work. Thanks for lot!
@bernhard111
@bernhard111 6 лет назад
Thank you for this great video!
@TheGari4ik
@TheGari4ik 6 лет назад
Thanks a lot, but don't working((( ubuntu server 4.4.0 & mysql 5.7.2.2 this methods (dpkg-reconfigure mysql-server) & (mysqld_safe --skip-grant-tables &) not approach. Help!
@arthborg
@arthborg 5 лет назад
Thanks, helped me a lot!
@ianwashere12345
@ianwashere12345 Год назад
Thank you. I can't tell you how you helped but lots of medical doctors now have access to their stuff.
@h.jpouya4715
@h.jpouya4715 3 года назад
you saved me man. I was about to reinstall my Linux. thanks
@abhisespoudel4490
@abhisespoudel4490 4 года назад
thanks man u saved me i am so glad and so delighted
@gokou0017
@gokou0017 7 лет назад
great tutorial, helped me a lot.
@ankurmishra6562
@ankurmishra6562 3 года назад
you are too good bhai i spend 2 hour but did not achive this but your video guide me and i success to setup mypassword so thankyou so much
@KCAR99
@KCAR99 4 года назад
i make these steps but i don’t stop and restart the service, it works the same thank you
@AaronEstebanSEO
@AaronEstebanSEO 4 года назад
Hi, do you have a video on how to change password for phpmyadmin?
@TheDuppyman
@TheDuppyman 7 лет назад
Thank you, you helped me out of a jam.
@mateusspadari5171
@mateusspadari5171 5 лет назад
Thank you so much bro !!
@prasad1686
@prasad1686 4 года назад
Thank you for sharing the knowledge
@webpwnized
@webpwnized 7 лет назад
Thank you for watching. Please help! Up vote, subscribe or even support this channel at ru-vid.com (Click Support).
@charlietame1892
@charlietame1892 4 года назад
Thanks. Linux Mint 19.2 I got an odd message and it hung there but after hitting return it worked anyways. root@LM19:~# mysqld_safe --skip-grant-tables & [1] 9762 root@LM19:~# 2019-10-11T21:54:55.139138Z mysqld_safe Logging to syslog. 2019-10-11T21:54:55.146620Z mysqld_safe Logging to '/var/log/mysql/error.log'. 2019-10-11T21:54:55.152069Z mysqld_safe Directory '/var/run/mysqld' for UNIX socket file don't exists.
@mansourahmed5170
@mansourahmed5170 4 года назад
@@charlietame1892 Have you tried simply creating this directory yourself, and restarting the service? mkdir -p /var/run/mysqld chown mysql:mysql /var/run/mysqld
@elwinjyothis5388
@elwinjyothis5388 3 года назад
I am getting an error at updating authentication_string the PASSWORD() function is not working! Please help me!!
@hamyid
@hamyid 5 лет назад
Thank you very much for your kind help
@mayaramarques5703
@mayaramarques5703 6 лет назад
Thank you so much!
@elephant_888
@elephant_888 5 лет назад
Thanks man!!
@luanraithz2494
@luanraithz2494 6 лет назад
Thanks a lot!!!
@sandinom.coelho5425
@sandinom.coelho5425 5 лет назад
LOVE YOU!
@shagunvaish4670
@shagunvaish4670 5 лет назад
it works but inlast there is a spelling mistake->update user set plugin = "mysql_native_passwor" where user='root'; which results the error in loging in please help me out and the error is ERROR 1524 (HY000): Plugin 'mysql_native_passwor' is not loaded
@frankmaponya8855
@frankmaponya8855 5 лет назад
It worked, Thanks
@cheojeg
@cheojeg 5 лет назад
You save my life with thist video
@karttal6799
@karttal6799 5 лет назад
Gracias ! tuve tantos problemas para cambiar la contraseña del usuario root y era tan simple, crack.
@cristianvergel6732
@cristianvergel6732 4 года назад
ERROR 1064 (42000): You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near '("password")' at line 1
@toiedo
@toiedo 3 года назад
Did you fix it?
@viveksanganna2014
@viveksanganna2014 3 года назад
@@toiedo - Password hash is depricated, try this instead update user set authentication_string = CONCAT('*', UPPER(SHA1(UNHEX(SHA1('password123'))))) where user='root';
@aswin_p.m
@aswin_p.m 2 года назад
@@viveksanganna2014 Thank you Vivek ! I was having a hard time solving and this command saved my day.
@ajayjayswal9139
@ajayjayswal9139 5 лет назад
Thank you very much sir
@Janther12
@Janther12 4 года назад
thank you very much :)
@nileshbharsawade3242
@nileshbharsawade3242 3 года назад
great! thanks a lot!
@mahdimehrabi1922
@mahdimehrabi1922 4 года назад
you are best , very very very thank you
@akgsbg
@akgsbg 7 лет назад
asking password to stop service and i for got password
@pawemateja2796
@pawemateja2796 6 лет назад
thanks a lot!
@ucheduk8186
@ucheduk8186 5 лет назад
Thanks so much
@red5hat
@red5hat 6 лет назад
update command not working, saying its an error. Please tell what to do.
@webpwnized
@webpwnized 6 лет назад
Try searching on the specific error. For example, copy and paste the error into DuckDuckGo.
@XushnudbekXudoynazarov
@XushnudbekXudoynazarov 4 года назад
what will be our password?(password("password")???)
@isaachuston182
@isaachuston182 6 лет назад
hey dude, i have this Error, can u helpme please??? ERROR 2002 (HY000): Can't connect to local MySQL server through socket '/var/run/mysqld/mysqld.sock' (2)
@novus7654
@novus7654 6 лет назад
Come to check this out: stackoverflow.com/questions/42153059/mysqld-safe-directory-var-run-mysqld-for-unix-socket-file-dont-exists
@akashgupta13
@akashgupta13 6 лет назад
Thanks a ton @Novus ! :D
@Nano-ih3ig
@Nano-ih3ig 5 лет назад
try sudo /etc/init.d/mysql start
@sandinom.coelho5425
@sandinom.coelho5425 5 лет назад
LOVE YOU!!!
@ThegeekTools
@ThegeekTools 4 года назад
@@Nano-ih3ig you are the man man ^__^
@Daijyobanai
@Daijyobanai 5 лет назад
When I type:: # mysqld_safe --skip-grant-tables & the terminal hangs, it never returns back to the prompt after printing: mysqld_safe Starting mysqld daemon with databases from /var/lib/mysql I'm on SalixOS latest. If I ctrl+c to return the prompt i get: [1] Done but whether I do that or not, this happens: $sudo mysql -u root ERROR 2002 (HY000): Can't connect to local MySQL server through socket '/var/run/mysql/mysql.sock' (2 "No such file or directory") and that is after trying the fix linked below, like so: mkdir -p /var/run/mysqld chown mysql:mysql /var/run/mysqld
@webpwnized
@webpwnized 5 лет назад
You might try to just hit Enter key after printing: mysqld_safe Starting mysqld
@jimmyhilman5612
@jimmyhilman5612 5 лет назад
Thanks
@dancing_frank_lee
@dancing_frank_lee 4 года назад
saved my life
@linhtrannhat286
@linhtrannhat286 4 года назад
select PASSWORD("password") is not working for me. ERROR 1064 (42000): You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near '("password")' at line 1 please help me
@mikeburger6735
@mikeburger6735 3 года назад
Did you put the ; at the end?
@navaneethkrishnan3827
@navaneethkrishnan3827 3 года назад
Thankyou
@lmcst2821
@lmcst2821 4 года назад
Please help mysql> select PASSWORD("password"); ERROR 1064 (42000): You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near '("password")' at line 1
@webpwnized
@webpwnized 4 года назад
Try single quotes
@andrewdoolittle
@andrewdoolittle 4 года назад
@@webpwnized single quotes and no quotes do not work either.
@maxl6753
@maxl6753 5 лет назад
thank you my database-god *.*
@maxl6753
@maxl6753 5 лет назад
love ya
@maxl6753
@maxl6753 5 лет назад
jeremy super typ
Далее
It seems Sonya's choice was obvious! 😅 #cat #cats
00:20
How To Install MySQL on Ubuntu 22.04 LTS (Linux)
12:50
Просмотров 109 тыс.
Hidden Password Input in Python
9:40
Просмотров 14 тыс.
Introduction to Network Packet Analysis with Wireshark
19:26
Introduction to Vulnerability Assessment with Nessus
24:15