Neither. This is exclusionary, initiation-based salvation, proving the Catholic Church to be a mystery cult based in allegorical performative ritual.
Grace-based salvation is exclusionary and Gnostic, requiring personal revelation. It allows those who have dedicated their lives to evil to obtain salvation while those who do nothing but good all their lives, but who do not expereince Gnosis are damned.
Salvation by works is not a Christian belief proper, since if universally applied it would allow non-Christians who do good in the world to be saved regardless of religion.
No religion can properly deal with the question of what happens to good people who don't follow its' faith and teachings.