Bring about one's own downfall, do oneself irreparable harm, as in
In taking his secretary to a risqué nightclub, the parish priest was signing his own death warrant . This expression may refer to acts that ensure someone's later murder, as when, in 1921, the Irish revolutionary leader Michael Collins signed the peace treaty he had negotiated with England and said, "I tell you, I have signed my death warrant." Thirteen months later Collins was assassinated by political opponents. The expression is also used hyperbolically, however, for severe repercussions or punishments. [First half of 1900s] Also see
shoot oneself in the foot.