This script is used to check the UUID (Universally Unique Identifier) of the computer's CSProduct. It performs the following steps:

  1. Uses the wmic command to get the UUID of the CSProduct.
  2. Uses findstr to filter out the "UUID" header from the output.
  3. Uses findstr to check if the UUID contains any alphanumeric characters. If it does, it goes to the UUIDFail label.
  4. Appends the UUID to a file called "uuid.txt" using >>.
  5. Uses a for loop to set the uuid variable to the value of the UUID.
  6. Uses find to count the occurrences of the UUID in the "uuid.txt" file.
  7. If the count is greater than 5, it displays a failure message and changes the console color to red.
  8. Uses another for loop to count the occurrences of "-" in the "uuid.txt" file.
  9. If the count is greater than 50, it deletes the "uuid.txt" file.

Note: The script assumes that there is a label called UUIDFail defined elsewhere in the script

wmic csproduct get uuid findstr V UUID findstr i a-zA-Z0-9 if errorlevel neq 0 goto UUIDFail wmic csproduct get uuid findstr V UUID find i - if errorlevel neq 0 goto UUIDFail wmic csproduct get

原文地址: https://www.cveoy.top/t/topic/hEU0 著作权归作者所有。请勿转载和采集!

免费AI点我,无需注册和登录