Hoist with his own petard
All references to Hamlet, unless otherwise specified, are taken from the Folger Shakespeare Library's Folger Digital Editions texts edited by Barbara Mowat, Paul Werstine, Michael Poston, and Rebecca Niles. Under their referencing system, 3.4.225 means act 3, scene 4, line 225.