A couple of ideas that you may or may not find suitable:
a) Rename the CHGPWD command to IBMCHGPWD and then create your own command called CHGPWD that calls your own program as its CPP. Put your CHGPWD command in a user library that is part of the *SYSLIBL. If you ever need to run the original CHGPWD you simply use IBMCHGPWD instead.
b) Add a command validation program to the CHGPWD command that calls your own program. I’m not sure whether or not you can “cancel” out of the CHGPWD command after running your own program so that the CHGPWD processing program is not called.
Out of the two I’d go with the first suggestion.
Hope it helps