You lose -all- user data with a factory reset including encryption keys.
I would delete your Google account and to be on the safe side screen lock as well before resetting. Do the reset through settings rather than from the boot menu to make sure FRP doesn't raise its ugly head. Redundantly backup all critical data before resetting!!!
What are trying to do?
If the data is already encrypted, after the reset it will be useless as the encryption key is gone.
If you're really paranoid reset, then file it with junk data, reset again.
Or use my favorite zero fill method... a 5# sledge hammer; strike briskly a dozen times on concrete, deleted.
How would you know the key?
People lose data like this all the time and they never get it back.
Simply encrypt again after the first factory reset, then factory reset. No one could know what the key -was-.