The following command, or whichever is appropriate for your kernel version, can be executed with BigFix. I tested it on a RHEL system and was able to reset the root password.
#!/bin/sh
# Enter your action script here
echo "mysecure" | passwd root --stdin > /dev/null
To prevent your plaintext password from being revealed, you need to utilise a security parameter to conceal it. Here’s an example:
https://bigfix.me/fixlet/details/26939