If specific blocks (FBs or FCs) are locked with "Know-How Protection," these are separate from the CPU password. If you lose this password, those specific blocks cannot be opened or edited, even if you have the rest of the project.
If you are locked out of an S7-1200 PLC, you cannot simply bypass or read the password out of the device due to advanced encryption. However, you can regain control of the hardware using official reset methods, or recover the program if you possess the original source files. Understanding S7-1200 Security Levels S7-1200 Password Unlock
Users cannot read or write data, nor can they view the code without the password. If specific blocks (FBs or FCs) are locked