![]() |
nano syntax highlighting masks - Printable Version +- hashcat Forum (https://hashcat.net/forum) +-- Forum: Misc (https://hashcat.net/forum/forum-15.html) +--- Forum: User Contributions (https://hashcat.net/forum/forum-25.html) +--- Thread: nano syntax highlighting masks (/thread-8382.html) |
nano syntax highlighting masks - 2048 - 05-28-2019 ![]() Made a really simple nanorc file to highlight syntax in mask files if you open them in the nano text editor. If you make a small mistake like ?? or dd it will highlight it in red. Instructions add your .nanorc file: include "~/.nano/hcmask.nanorc" command to include: Code: echo 'include "~/.nano/hcmask.nanorc"' >> ~/.nanorc copy this code to ~/.nano/hcmask.nanorc Code: # nano syntax highlighting for hashcat hcmask files If you only want the warnings use the lines below "# gives warning". RE: nano syntax highlighting masks - philsmd - 05-28-2019 interesting. thanks for the contribution. ... but I think your syntax rules do not catch all cases see: 1. https://hashcat.net/wiki/doku.php?id=mask_attack#hashcat_mask_files 2. https://hashcat.net/wiki/doku.php?id=frequently_asked_questions#what_is_a_hashcat_mask_file for instance ?? is perfectly fine syntax: it means use the dollar AS-IS without interpreting it as a built-in or custom charset reference. Furthermore, there is the \, and \# rule and we have these built-in charsets: ?l, ?u, ?d, ?h, ?H, ?s, ?a, ?b as you can see from the hashcat --help output of course this can be easily improved (at least some of those missing syntax rules are quite easy to add to the rc file). One thing that some users also do not understand is that ?a?abbbbb?a?a is a perfectly fine mask. It means that the string "bbbbb" is both prefixed and suffixed by 2 characters (?l?u?d?s). so we can have constant (hard-coded) strings within the mask too. RE: nano syntax highlighting masks - 2048 - 05-29-2019 Thank you for your comment. I don't understand "dollar AS-IS". From the hashcat output I see that you can use it as a question mark. Code: $ hashcat --stdout -a 3 ?????d I had the problem that I sometimes didn't see mistakes like ?? when editing mask files, so this is a quick 'n dirty "hack". |