I saw PHP 5.6 code used from a CMS that takes some data about the database connections used for a site, it creates a string, and obtains its SHA256 hash. (That value is usually considered a salt from the CMS.) When it needs a HMAC, it uses that SHA256 hash concatenated with the inode change time and the inode value (for the file containing the executed code).
I know that an SHA256 hash is not distinguishable from random output, but is there a better way to obtain a HMAC key that is used for short periods (for example, when running tests)?
I know that an SHA256 hash is not distinguishable from random output, but is there a better way to obtain a HMAC key that is used for short periods (for example, when running tests)?