I won't lie: this is a wrinkle in the rules that I've been confounded by for years myself. I wouldn't describe it a loophole exactly because that would suggest that teams could actively or nefariously seek to exploit it (which, given that it relies on long-term injuries to its players, is unlikely), but it's paramount to maintain the integrity and fairness of competition especially in the postseason.
On the one hand, the playoffs are more than two months of grueling attrition so realistically you can't expect to bar a team from activating a key player that recovers from injury when everything is on the line, but deciding the salary cap doesn't exist anymore creates a most unpalatable paradox.
I think the solution could be as simple as calculating the salary of dressed players any given game night and otherwise enforcing the cap as normal (or, at the very least, padding the cap by a million or so to acknowledge the complexity of injury management and giving teams some degree of flexibility). Want to load up the top line with that blockbuster replacement/rental? Gotta gut some depth to pull it off, or otherwise make some tough roster decisions.
Has anybody crunched the numbers for Cup champions to see if this has been proven to pose a material advantage over the years? I've always lauded the NHL for committing to a hard cap (I've long had a beef with soft/luxury cap leagues and wish other sports would negotiate more equitable arrangements, although that's another lengthy tangent indeed), so it would be a shame if such a correlation was indisputably established.