LinuxQuestions.org
Latest LQ Deal: Linux Power User Bundle
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie
User Name
Password
Linux - Newbie This Linux forum is for members that are new to Linux.
Just starting out and have a question? If it is not in the man pages or the how-to's this is the place!

Notices


Reply
  Search this Thread
Old 03-24-2015, 03:12 AM   #1
prasad1990
LQ Newbie
 
Registered: Feb 2015
Posts: 11

Rep: Reputation: Disabled
Compare given password and regexp with password length


Hello friends,

I want to compare regexp and password, Including password length using shell script.

password=az*12345
regexp=^[a-zA-Z]{2}[*][0-9]{5}$

please let me know
thanks in advance.

Last edited by prasad1990; 03-24-2015 at 06:43 AM.
 
Old 03-24-2015, 04:27 AM   #2
TenTenths
Senior Member
 
Registered: Aug 2011
Location: Dublin
Distribution: Centos 5 / 6 / 7
Posts: 2,166

Rep: Reputation: 751Reputation: 751Reputation: 751Reputation: 751Reputation: 751Reputation: 751Reputation: 751
Ok, what have you written so far?
 
Old 03-24-2015, 10:50 AM   #3
grail
LQ Guru
 
Registered: Sep 2009
Location: Perth
Distribution: Manjaro
Posts: 9,252

Rep: Reputation: 2685Reputation: 2685Reputation: 2685Reputation: 2685Reputation: 2685Reputation: 2685Reputation: 2685Reputation: 2685Reputation: 2685Reputation: 2685Reputation: 2685
Looks good so far. Where are you stuck? I would recommend some quotes
 
Old 05-02-2015, 11:17 PM   #4
prasad1990
LQ Newbie
 
Registered: Feb 2015
Posts: 11

Original Poster
Rep: Reputation: Disabled
I got answer for that guys.. thanks, i will share it with you..
 
  


Reply

Tags
php, shell script


Thread Tools Search this Thread
Search this Thread:

Advanced Search

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
Password length validation Agustina Linux - Software 2 07-17-2012 06:09 PM
Minimum password length Domskis Linux - Newbie 4 10-20-2011 03:32 AM
Compare LDAP password with php crypt password coolamit78 Linux - Networking 1 01-30-2006 06:35 AM
Password length ust Linux - Distributions 1 04-06-2005 06:18 AM
Password length in SuSE 8.0 odin123 Linux - Security 3 05-24-2002 04:12 PM


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

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
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration