sstp-client: Could not create password hash

Aperta Adatta ai principianti
#31,407 1 commento 0 reazioni 0 assegnatari Vedi su GitHub

I maintainer di solito rispondono entro 1 giorno

Nessuno ha ancora preso questa issue.

Valutazione

Difficoltà
2/5
Tempo stimato
1-3 ore
Idoneità per principianti
62/100
Tipo di issue
Bug
Chiarezza
Abbastanza chiara
Stato di attività
Attiva
Stack tecnologico
c

Direzione di ricerca

Inizia dal Makefile del pacchetto sstp-client e dalla sua riga DEPENDS, che attualmente elenca +libopenssl ma non +libopenssl-legacy. Conferma che il fallimento dell'hash NT (MD4) nel log deriva dal provider legacy di OpenSSL mancante e verifica se il maintainer concorda con la dipendenza proposta o preferisce una documentazione. Il lavoro è completo quando esiste una modifica alla dipendenza o una nota nella documentazione e un'immagine pulita con sstp-client riesce a stabilire un tunnel SSTP MS-CHAPv2.

Scritto dal modello di indicizzazione a partire dal testo della issue.

Descrizione

bug
Package Name

sstp-client

Maintainer

@Federico Di Marco

OpenWrt Version

25.12.6

OpenWrt Target/Subtarget

mediatek/filogic

Steps to Reproduce

After upgrading to a firmware with sstp-client 1.0.20 (and pppd 2.5.x), an SSTP connection to a Windows RRAS-style server (MS-CHAPv2) that worked with sstp-client 1.0.15 now fails. PPP authentication succeeds, but the server immediately aborts the session right after sstpc sends the Connected message with the Crypto Binding attribute:

sstpc[4379]: Connected to sstp.example.com
sstpc[4379]: Started PPP Link Negotiation
pppd[4381]: pppd 2.5.2 started by root, uid 0
sstpc[4379]: Could not create password hash
pppd[4381]: CHAP authentication succeeded
sstpc[4379]: Sending Connected Message
sstpc[4379]: SEND SSTP CRTL PKT(112)
sstpc[4379]:     CRYPTO BIND(3): 104
sstpc[4379]: Connection Established
sstpc[4379]: RECV SSTP CRTL PKT(20)
sstpc[4379]:   TYPE(5): ABORT, ATTR(1):
sstpc[4379]:     STATUS INFO(2): 12
pppd[4381]: Terminating on signal 15
pppd[4381]: Modem hangup

The user-visible error is Connection was aborted, Value of attribute is incorrect (status 12): the server rejects the Crypto Binding attribute.

Cause (as far as I can tell):

Could not create password hash appears to come from the NT hash computation (MD4 of the UTF-16LE password) that sstpc uses to derive the MPPE keys for the Crypto Binding. In OpenSSL 3, MD4 lives in the legacy provider, which on OpenWrt is a separate package (libopenssl-legacy). Without it the hash cannot be created, the keys are wrong/empty, the Compound MAC is invalid, and the server aborts the connection. This explains why 1.0.15 worked and 1.0.20 does not on a fresh image.

After installing libopenssl-legacy the error disappears and the tunnel comes up.

Suggested fix:

The package currently depends on +libopenssl but not on +libopenssl-legacy. Please consider adding +libopenssl-legacy to DEPENDS of sstp-client (or at least documenting the requirement), since MS-CHAPv2 key derivation fails without it.

Config used (credentials removed):

config interface 'sstp0'
	option proto 'sstp'
	option server 'sstp.example.com'
	option log_level '4'
	option username '***'
	option password '***'
	option peerdns '0'
	option metric '60'
	option pppd_options 'defaultroute-metric 60'
Actual Behaviour

none

Confirmation Checklist
Lingua principale
Makefile
Stelle
4.7k
Fork
4k
Merge medio
3g 13h
PR unite (30g)
313

Preparare l'ambiente

Apri in Codespaces

Avvia il container di sviluppo del progetto nel browser, con il tuo account GitHub.

Come iniziare

  1. Leggi tutta la issue e poi la guida ai contributi del progetto.
  2. Commenta sulla issue per dire che te ne occupi tu — evita che due persone facciano lo stesso lavoro.
  3. Fai un fork del repository e lavora su un branch.
  4. Apri una pull request che faccia riferimento al numero della issue.

Altre issue di openwrt/packages

Tutte le issue di openwrt/packages

Issue simili

Altre issue su Build System

Ricevi le nuove issue nella tua casella

Un breve riepilogo di issue GitHub adatte ai principianti.