@@ -105,25 +105,25 @@ def output_tgs(self, tgs, old_session_key, session_key, username, spn, fd=None):
105105 return entry
106106
107107 def output_tgs_from_asrep (self , asrep_blob , spn , fd = None ):
108- asrep = decoder .decode (asrep_blob , asn1Spec = AS_REP ())[0 ]
109- realm = self .domain .upper ()
110- enc = asrep [' ticket' ][ ' enc-part' ]
111- etype = enc [' etype' ]
112- cipher = enc [' cipher' ].asOctets ()
108+ asrep = decoder .decode (asrep_blob , asn1Spec = AS_REP ())[0 ]
109+ realm = self .domain .upper ()
110+ enc = asrep [" ticket" ][ " enc-part" ]
111+ etype = enc [" etype" ]
112+ cipher = enc [" cipher" ].asOctets ()
113113
114- service = spn .split ('/' )[0 ]
114+ service = spn .split ("/" )[0 ]
115115 spn_fmt = spn .replace (":" , "~" )
116116
117117 if etype == constants .EncryptionTypes .rc4_hmac .value : # 23
118- chk = hexlify (cipher [:16 ]).decode ()
118+ chk = hexlify (cipher [:16 ]).decode ()
119119 data = hexlify (cipher [16 :]).decode ()
120120 entry = f"$krb5tgs${ etype } *{ service } ${ realm } ${ spn_fmt } *${ chk } ${ data } "
121121
122122 elif etype in (
123123 constants .EncryptionTypes .aes128_cts_hmac_sha1_96 .value , # 17
124124 constants .EncryptionTypes .aes256_cts_hmac_sha1_96 .value , # 18
125125 ):
126- chk = hexlify (cipher [- 12 :]).decode ()
126+ chk = hexlify (cipher [- 12 :]).decode ()
127127 data = hexlify (cipher [:- 12 ]).decode ()
128128 entry = f"$krb5tgs${ etype } ${ service } ${ realm } $*{ spn_fmt } *${ chk } ${ data } "
129129
0 commit comments