1274 The Holy Spirit has marked us with the seal of the Lord ("Dominicus character") "for the day of redemption." 86 "Baptism indeed is the seal of eternal life." 87 The faithful Christian who has "kept the seal" until the end, remaining faithful to the demands of his Baptism, will be able to depart this life "marked with the sign of faith," 88 with his baptismal faith, in expectation of the blessed vision of God - the consummation of faith - and in the hope of resurrection.
The Catechism teaches that the baptismal mark is necessary for the beatific vision.
St Alphonsus says that BOD does not provide the indelible mark.
But baptism of desire is perfect conversion to God by contrition or love of God above all things accompanied by an explicit or implicit desire for true Baptism of water, the place of which it takes as to the remission of guilt, but not as to the impression of the [baptismal] character or as to the removal of all debt of punishment.
Ergo, it is unclear what happens to an unbaptized but justified person when they die. The Church does not clearly say.