How does your solution compare to the one described in this comment on “The beauty and terror of modding Windows”? https://news.ycombinator.com/item?id=47231364