Blame SOURCES/fix-issue-530-NLA-password-asked-after-certificate-r.patch

0c7016
From 3941b9078775c31e37b8b4bd89cee06beac3aef1 Mon Sep 17 00:00:00 2001
0c7016
From: =?UTF-8?q?Rapha=C3=ABl=20Rigo?= <devel-freerdp@syscall.eu>
0c7016
Date: Tue, 10 Apr 2012 22:24:08 +0200
0c7016
Subject: [PATCH 2/5] fix issue #530 "NLA password asked after certificate
0c7016
 refusal" close connection when the certificate is not trusted
0c7016
0c7016
---
0c7016
 libfreerdp-core/tls.c | 5 ++++-
0c7016
 1 file changed, 4 insertions(+), 1 deletion(-)
0c7016
0c7016
diff --git a/libfreerdp-core/tls.c b/libfreerdp-core/tls.c
0c7016
index 942b430..b05100e 100644
0c7016
--- a/libfreerdp-core/tls.c
0c7016
+++ b/libfreerdp-core/tls.c
0c7016
@@ -80,8 +80,11 @@ boolean tls_connect(rdpTls* tls)
0c7016
 		return false;
0c7016
 	}
0c7016
 
0c7016
-	if (!tls_verify_certificate(tls, tls->cert, tls->settings->hostname))
0c7016
+	if (!tls_verify_certificate(tls, tls->cert, tls->settings->hostname)) {
0c7016
+		printf("tls_connect: certificate not trusted, aborting.\n");
0c7016
 		tls_disconnect(tls);
0c7016
+		return false;
0c7016
+	}
0c7016
 
0c7016
 	return true;
0c7016
 }
0c7016
-- 
0c7016
2.5.5
0c7016