Yeah, ok, I'm at this point just posting in an attempt to clarify what I was saying before. Consider this post to overwrite the last one I made.
For Heretic of the Faith to protect something, it has to be a class feature (or spell, but let's ignore that for now), and it has to be one you'd lose purely as a consequence of violating your deity's code of conduct, WHATEVER that code of conduct may be. As in, it has to be contingent upon having the "Code of Conduct" class feature, or, arguably, Cleric restriction. It can't merely be that your code of conduct contains "have VoP", because your having VoP is not contingent on adhering to your Code of Conduct (mechanically; in terms of character behavior, it is, but that's not what we're talking about here). Is the distinction I'm getting at clear here? If having Vow of Poverty isn't something that depends on following a code, then you can't lose it by breaking that code; even if the same action violates both, you lose Vow of Poverty for the action, not for violating the code.
As I see it, the only way to satisfy the first requirement is to get Vow of Poverty as a class feature-granted bonus feat. The only way to satisfy the second is to gain that bonus feat from a class feature that you lose when you violate your Code of Conduct class feature, in the same way that a fallen paladin loses his mount. There are only a few things that satisfy both requirements, to my knowledge.
First, gaining VoP as a bonus feat from following an Elder Good. If your Code of Conduct contains, "Follow the Elder Good", then now you gain bonus feats as a consequence of having your Code of Conduct, and those bonus feats are all contingent upon adhering to it. You need to be a Paladin for this to work, otherwise your Code of Conduct is not a class feature; a Cleric doesn't have a Code of Conduct as a class feature, which means that VoP isn't a class feature-granted bonus feat, and therefore is not eligible for protection under HotF. You need to be in Faerun for this to work, otherwise you can't make additions or modifications to your Code of Conduct in order to account for your deity without pure DM Fiat (as far as I'm aware). Whether VoP's requirements still apply is arguable, but you can claim that the entirety of Vow of Poverty, including its restrictions, is part of your Code of Conduct, and therefore something you can grossly violate. That's good enough for me. Note that this only works because a Paladin loses his Code of Conduct upon violating it.
Secondly, a prestige or base class other than Paladin or Cleric that has a class feature that functions similarly works just as well. If the class grants bonus feats which are dependent on adhering to the code, you don't need the Elder Good and don't need an explicit "Code of Conduct" class feature for everything to be dependent upon. If you require the Elder Good, you need a code which you can modify in order to include "Follow the Elder Good".
EDIT: A cleric with a domain that grants a bonus feat, Dark Chaos Shuffled to Vow of Poverty, also works, but is very silly. Works in any setting, though. All methods other than the Explicit Code of Conduct+Elder Good one (which accounts for everything already) require having "Adhere to the requirements of Vow of Poverty", explicitly referencing Vow of Poverty, in order to work, so that violating VoP is an act of violating one's code by that reason alone, and thus is protected.
And yes, I'm trying to hold the RAW to the strictest possible interpretation. When you're arguing for silly things like "Vow of Poverty, but with equipment!" that's sort of the position you have to hold. It clearly flies in the face of RAI, after all.
And Grey Guard is just SO much simpler to reason through because of the insanely vague wording of its capstone.