Skip to content

Commit

Permalink
Add version info for ccapi dll
Browse files Browse the repository at this point in the history
Without version info, this library would not get installed during
an upgrade scenario, causing the MIT Kerberos application to crash
on startup.

Signed-off-by: Kevin Wasserman <kevin.wasserman@painless-security.com>

[kaduk@mit.edu: add motivation to commit message]

ticket: 7336 (new)
subject: Fix KfW crash on startup after upgrade
queue: kfw
target_version: 1.10.4
tags: pullup
  • Loading branch information
Kevin Wasserman authored and kaduk committed Aug 29, 2012
1 parent 9470259 commit 69d4743
Show file tree
Hide file tree
Showing 2 changed files with 18 additions and 2 deletions.
9 changes: 7 additions & 2 deletions src/ccapi/lib/win/Makefile.in
Original file line number Diff line number Diff line change
Expand Up @@ -89,10 +89,15 @@ copysrc :

midl : ccs_request.h ccs_reply.h

VERSIONRC = $(BUILDTOP)\..\windows\version.rc
CCLIBRES = (OUTPRE)$(CCLIB).res
# Main program:
$(OUTPRE)$(CCLIB).dll: $(OBJS) $(CCLIB).def
$(CCLIBRES): $(VERSIONRC)
$(RC) $(RCFLAGS) -DCCAPI_LIB -fo $@ -r $**

$(OUTPRE)$(CCLIB).dll: $(OBJS) $(CCLIB).def $(CCLIBRES)
$(LINK) $(LFLAGS) -entry:$(ENTRYPOINT) -dll /map:$*.map /out:$@ /DEF:$(CCLIB).def $(OBJS) \
/implib:$(CCLIB).lib $(dllflags) $(LIBS) $(KFWLIB) $(SCLIB) rpcrt4.lib $(conlibsdll) $(conflags)
/implib:$(CCLIB).lib $(dllflags) $(LIBS) $(KFWLIB) $(SCLIB) $(CCLIBRES) rpcrt4.lib $(conlibsdll) $(conflags)

$(CCLIB).def:
echo ;$(CCLIB).def is generated by a Makefile rule. > $(CCLIB).def
Expand Down
11 changes: 11 additions & 0 deletions src/windows/version.rc
Original file line number Diff line number Diff line change
Expand Up @@ -108,6 +108,17 @@
#endif
#endif /* GSSAPI */

#ifdef CCAPI_LIB
#define K5_DESCRIPTION "Kerberos Credentials Cache DLL\0"
#define K5_INTERNAL_NAME "krbcc\0"
#define K5_FILETYPE VFT_DLL
#if defined(_WIN64)
#define K5_ORIGINAL_NAME "krbcc64.dll\0"
#else
#define K5_ORIGINAL_NAME "krbcc32.dll\0"
#endif
#endif /* CCAPI_LIB */

#ifdef LEASH_APP
#define K5_DESCRIPTION "MIT Kerberos Ticket Manager - " KRB5_PRODUCTNAME_STR "\0"
#define K5_FILETYPE VFT_APP
Expand Down

0 comments on commit 69d4743

Please sign in to comment.