LinuxQuestions.org
Welcome to the most active Linux Forum on the web.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Security
User Name
Password
Linux - Security This forum is for all security related questions.
Questions, tips, system compromises, firewalls, etc. are all included here.

Notices


Reply
  Search this Thread
Old 09-15-2015, 11:01 AM   #1
khpr0502
LQ Newbie
 
Registered: Jun 2011
Posts: 6

Rep: Reputation: Disabled
How to check if root password and grub password is same or not on RHEL 7 .


Hi I am trying to come up with a plan to write a script for syncing root password and grub password on RHEL 7.
If it was RHEL 6/5/4, I would simply compare shadow and grub.conf file,
but on RHEL 7 how can we acheive this. RHEL 7 uses grub2.cfg and their hash are different. Is there any other way I can accomplish this ?
Need a way to compare root and grub password and change if required ?

Thanks

Last edited by khpr0502; 09-15-2015 at 11:38 AM.
 
Old 09-15-2015, 11:59 AM   #2
Melanie
LQ Newbie
 
Registered: Jan 2003
Location: London, UK
Distribution: CentOS, Fedora
Posts: 4

Rep: Reputation: 1
Use a PAM plugin

This points to the source of a little program included with Samba. It is a pam plugin and will allow you to trigger an action whenever a password is changed. It should be easy to adapt it to change the grup2 password rather than the Samba database.

http://opensource.apple.com/source/s...e/pam_smbpass/
 
Old 09-16-2015, 08:36 AM   #3
odjb
Member
 
Registered: Jan 2006
Location: France
Distribution: Ubuntu/Debian
Posts: 69

Rep: Reputation: 1
Hello,
If passwords were hashed with the same method, identical hashes would mean identical passwords. AFAIK, in the case of different hash methods, there is no way to find matches between passwords as the hash is meant to not having the ability to retrieve the password from the hash.
 
Old 09-21-2015, 09:36 AM   #4
khpr0502
LQ Newbie
 
Registered: Jun 2011
Posts: 6

Original Poster
Rep: Reputation: Disabled
Thanks for the response guys. I also feel the same, it is not an easy task as hash value are different. I am researching methods if I can incorporate Melanie's suggestion and implement it.

Thanks again.
 
  


Reply

Tags
bash, linux, scripting, security



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
GRUB security. -How do I properly set, and double check the grub bootloader password? bwilky11 Debian 3 11-02-2012 08:22 PM
i forget my root password. how to login in root account with new password in red hat. balajiraja Linux - Desktop 3 08-22-2012 01:41 AM
how to change root password without knowing the grub password ramesh.mimit Red Hat 8 10-15-2011 05:12 AM
change Root Password even if the password in the grub is also set sheelnidhi Linux - General 6 08-30-2006 07:27 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - Security

All times are GMT -5. The time now is 04:04 AM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration