WP nonce verification

If this is coming from a form you can use this code to add the nonce to it:

// Create an nonce, and add it as a query var in a link to perform an action.
$nonce = wp_create_nonce( 'my-nonce' );

<form action='youraction?_wpnonce=<?php echo $nonce?>'>
    <!-- Form Contents -->
</form>

Then you can add this to where you are processing the form:

$nonce = $_REQUEST['_wpnonce'];

if ( ! wp_verify_nonce( $nonce, 'my-nonce' ) ) {

     die( 'Security check' ); 

} else {

     // Do stuff here.
}