krb5 commit: Set kfw GUI read-only princ flag when appropriate

Benjamin Kaduk kaduk at MIT.EDU
Mon Aug 27 11:52:07 EDT 2012


https://github.com/krb5/krb5/commit/b89802f0a491c6e8c6a320bc1af2b2bbbdb92669
commit b89802f0a491c6e8c6a320bc1af2b2bbbdb92669
Author: Kevin Wasserman <kevin.wasserman at painless-security.com>
Date:   Thu Jun 21 13:27:27 2012 -0400

    Set kfw GUI read-only princ flag when appropriate
    
    When receiving a request to obtain tickets (from another process), if a
    particular principal is requested, set the read-only flag to prevent
    the user from changing the principal.
    
    Signed-off-by: Kevin Wasserman <kevin.wasserman at painless-security.com>
    
    ticket: 7275 (new)
    queue: kfw
    target_version: 1.10.4
    tags: pullup

 src/windows/leash/LeashView.cpp |    3 +++
 1 files changed, 3 insertions(+), 0 deletions(-)

diff --git a/src/windows/leash/LeashView.cpp b/src/windows/leash/LeashView.cpp
index 1375d9f..96c5127 100644
--- a/src/windows/leash/LeashView.cpp
+++ b/src/windows/leash/LeashView.cpp
@@ -2753,6 +2753,9 @@ CLeashView::OnObtainTGTWithParam(WPARAM wParam, LPARAM lParam)
         strcpy(ldi.in.title,"Get Ticket");
     }
 
+    if (strlen(ldi.username) > 0 && strlen(ldi.realm) > 0)
+        ldi.dlgtype |= DLGFLAG_READONLYPRINC;
+
     res = pLeash_kinit_dlg_ex(m_hWnd, &ldi);
     GlobalUnlock((HGLOBAL) lParam);
     ::SendMessage(m_hWnd, WM_COMMAND, ID_UPDATE_DISPLAY, 0);


More information about the cvs-krb5 mailing list