diff --git a/modules/adfs/lib/IdP/ADFS.php b/modules/adfs/lib/IdP/ADFS.php
index 5fc95f5053505ddd2ce28a531b3873b8497237da..d7fc51f117b4f77b3f0465f4f5c3eacbd94b8260 100644
--- a/modules/adfs/lib/IdP/ADFS.php
+++ b/modules/adfs/lib/IdP/ADFS.php
@@ -175,6 +175,13 @@ class sspmod_adfs_IdP_ADFS {
 	}
 	
 	public static function receiveLogoutMessage(SimpleSAML_IdP $idp) {
+		// if a redirect is to occur based on wreply, we will redirect to url as
+		// this implies an override to normal sp notification.
+		if(isset($_GET['wreply']) && !empty($_GET['wreply'])) {
+			$idp->doLogoutRedirect(SimpleSAML_Utilities::checkURLAllowed($_GET['wreply']));
+			assert(FALSE);
+		}
+
 		$state = array(
 			'Responder' => array('sspmod_adfs_IdP_ADFS', 'sendLogoutResponse'),
 		);