Using grep to match md5 hashes

前端 未结 4 716
独厮守ぢ
独厮守ぢ 2021-02-08 06:21

How can I match md5 hashes with the grep command?

In php I used this regular expression pattern in the past:

/^[0-9a-f]{32}$/i

But I t

4条回答
  •  野趣味
    野趣味 (楼主)
    2021-02-08 06:27

    You want this:

    grep -e "[0-9a-f]\{32\}" filename
    

    Or more like, based on your file format description, this:

    grep -e ":[0-9a-f]\{32\}" filename
    

提交回复
热议问题