Bug 39301 - replace "homebrew" DES encryption code with passlib.utils.des in univention-radius and univention-squid
replace "homebrew" DES encryption code with passlib.utils.des in univention-r...
Status: RESOLVED WONTFIX
Product: UCS
Classification: Unclassified
Component: Radius
UCS 4.0
Other Linux
: P5 normal (vote)
: UCS 4.0-x
Assigned To: UCS maintainers
:
Depends on: 38785
Blocks: 38794
  Show dependency treegraph
 
Reported: 2015-09-03 10:56 CEST by Felix Botner
Modified: 2019-01-03 07:17 CET (History)
3 users (show)

See Also:
What kind of report is it?: ---
What type of bug is this?: ---
Who will be affected by this bug?: ---
How will those affected feel about the bug?: ---
User Pain:
Enterprise Customer affected?: Yes
School Customer affected?:
ISV affected?:
Waiting Support:
Flags outvoted (downgraded) after PO Review:
Ticket number:
Bug group (optional):
Max CVSS v3 score:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Felix Botner univentionstaff 2015-09-03 10:56:01 CEST
We should consider replacing the DES code in univention-radius and univention-squid with passlib.utils.des.

univention-radius: univention/pyMsChapV2.py.DesEncrypt()

- convertKey()
- setOddParity()

- return pyDes.des(convertKey(key), pyDes.ECB).encrypt(data)
+ return passlib.utils.des.des_encrypt_block(key, data)

univention-squid: squid_ldap_ntlm_auth.verifyNtlm()

- convertKey()
- setOddParity()

- res1 = Crypto.Cipher.DES.new(convertKey(key[0:7])).encrypt(nonce)
- res2 = Crypto.Cipher.DES.new(convertKey(key[7:14])).encrypt(nonce)
- res3 = Crypto.Cipher.DES.new(convertKey(key[14:21])).encrypt(nonce)
+ res1 = passlib.utils.des.des_encrypt_block(key[0:7], nonce)
+ res2 =
Comment 1 Janek Walkenhorst univentionstaff 2015-09-09 10:47:46 CEST
That's a good idea, now that python-passlib is available.
One can also check if a python implementation of MSCHAPv2 is available since UCS 4.0.
Comment 2 Florian Best univentionstaff 2017-06-28 14:52:43 CEST
There is a Customer ID set so I set the flag "Enterprise Customer affected".
Comment 3 Stefan Gohmann univentionstaff 2019-01-03 07:17:14 CET
This issue has been filled against UCS 4.0. The maintenance with bug and security fixes for UCS 4.0 has ended on 31st of May 2016.

Customers still on UCS 4.0 are encouraged to update to UCS 4.3. Please contact
your partner or Univention for any questions.

If this issue still occurs in newer UCS versions, please use "Clone this bug" or simply reopen the issue. In this case please provide detailed information on how this issue is affecting you.