Asterisk (*) in the era of DOS, is the wildcard character (English called wildcard) representative. From DOS to Windows to PowerShell, the asterisk sticks to the wildcard post as usual.
Simply look at an example:
Copy Code code as follows:
PS [Zhanghong] >dir D:\*.vbs
Table of Contents: D:\
Mode LastWriteTime Length Name
---- ------------- ------ ----
-A---2013/6/5 16:42 211 test.vbs
The role of this example is to list all the files for the VBS suffix in the D-packing directory.
Small series often use PowerShell to deal with the path, how flexible from the directory system to take out their own files are small series has been the pursuit. Inadvertently, small braided now PowerShell path, you can use more than one wildcard character, thus greatly improve efficiency.
When we open a virtual host, we put all the user data in a directory of such a pattern:
Copy Code code as follows:
D:\wwwroot\ website Name \wwwroot\
If I want to find the index.php file at the root of all users ' sites, we can take a wildcard character in the path:
Copy Code code as follows:
Dir d:\wwwroot\*\wwwroot\index.php
Further, if we want to see all the files with index as the filename, that's OK:
Copy Code code as follows:
Dir d:\wwwroot\*\wwwroot\index.*
Hackers often like to name index or default file inside the black chain, we can use this way to quickly find the relevant documents, good for the next reconnaissance work.
OK, about the use of wildcards in the path, say so much, thank you!