From owner-freebsd-current@freebsd.org Wed Jun 7 17:34:40 2017 Return-Path: Delivered-To: freebsd-current@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 14B27C79E3E for ; Wed, 7 Jun 2017 17:34:40 +0000 (UTC) (envelope-from ohartmann@walstatt.org) Received: from mout.gmx.net (mout.gmx.net [212.227.15.15]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (Client CN "mout.gmx.net", Issuer "TeleSec ServerPass DE-2" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 6A6A77BF1B for ; Wed, 7 Jun 2017 17:34:38 +0000 (UTC) (envelope-from ohartmann@walstatt.org) Received: from thor.intern.walstatt.dynvpn.de ([78.52.128.66]) by mail.gmx.com (mrgmx003 [212.227.17.190]) with ESMTPSA (Nemesis) id 0Lj1Cw-1drRYj1sRq-00dGSH; Wed, 07 Jun 2017 19:29:23 +0200 Date: Wed, 7 Jun 2017 19:29:15 +0200 From: "O. Hartmann" To: Matthias Apitz Cc: freebsd-current@freebsd.org Subject: Re: mount_smbfs gives error when stored crypted pw is used Message-ID: <20170607192915.28088b71@thor.intern.walstatt.dynvpn.de> In-Reply-To: <20170607172234.GA3972@c720-r314251> References: <20170606100034.GA4245@c720-r314251> <20170606123738.GA5213@c720-r314251> <20170607123531.GA4867@c720-r314251> <20170607172234.GA3972@c720-r314251> Organization: WALSTATT User-Agent: OutScare 3.1415926 X-Operating-System: ImNotAnOperatingSystem 3.141592527 MIME-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha512; boundary="Sig_/IEq3dtuK6wSBbPAQ_kW830V"; protocol="application/pgp-signature" X-Provags-ID: V03:K0:u3wQSaJc2vf5sv0W1ongfVozxrCPkhR2iFITH4XyBipvxey8hAT CT5tf2rqI0mJG/wZkuM597LIgQMBmmzn8eGNISaBwtFg11qZFR81O36nfQJV8UhKHMrhyKY bmHm71WXLt6ASVFXhd7Qzh3MvwPwmCcKyH+zs7D5RRrc1zVcfC3RNduk0UHNV+PowbnU9M/ YvojYg5KF1xrTpgN0cQtQ== X-UI-Out-Filterresults: notjunk:1;V01:K0:BeaIHwiX/5o=:0sBo7aDBto+HdmMqnf5k3y QRxlUwNVqOYe9SJ9jpIvBAFhSdIoW5FFv7xRjH6MFDtrXSVaArG3PDfUNEEjLCTCEjSSGtc1A KIvjalRX/fQGgrRGo3sQMHd/vS8Qt8MDFyDcNyZBJ+dYcRBRlTPATCVVkUVZP/icyS30+uYDw ohvF5Pcgtt9QJRKN8AWetIoAqLd4hnnvSuC9Jq0MolIRW8/QPYXNodLqM/37O9W3BxYgnBbu5 yoRA65fE9WRlHKzF+udYzzWs8Fo7BeZvz4PkslhKwTrFlPNJ5WPIt2inlGvLJY3Nq5mrfkXwK rP6AFRGPO3gBSnMfsL1i256qfOwXSHKiHP6ukEKwehwQRhHBl4v8M0AUYx4Va1SdGEwNQ7ept eQ45wbY41hT+ukb5+Zsh4Z3dLjEI55KTSGWctDQcPUb+VjsYPzJvm01qc53RFfsxg/WxS4ZwL 3v0q378zjlsinZcEK5l0pp4zn57ZlLVnftRtbyw+h90iG+WrdZ1h6AyUMgjkETiu8xvAlaLfb zmql3Su7S3dOxGVCixkZYxoUWhpRdznNLoG3mwtCjAgRWyQLksjfhYxelZ63KXvwMevlGCeLT CJSCKTCTStDGLPW1vMP9HDfbt5XYKkESCfapkoHPQTje+7Avzt8hfDtIShHJ1eEqsio8nwOA0 6L3AwbU7c+HjcBeDxvUXnnLfAwZ6bATxLGnsv9KU7iIyvzV1+tyaqM4y9L4M0TLLs1aMptbuA fzHfpzMdepY8l/X6lOQKlJhDrbu7ec3lGmNQ7vK3Bsl4ytCITFN4wzcNvI0= X-BeenThere: freebsd-current@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: Discussions about the use of FreeBSD-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 07 Jun 2017 17:34:40 -0000 --Sig_/IEq3dtuK6wSBbPAQ_kW830V Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable Am Wed, 7 Jun 2017 19:22:34 +0200 Matthias Apitz schrieb: > El d=C3=ADa mi=C3=A9rcoles, junio 07, 2017 a las 02:35:31p. m. +0200, Mat= thias Apitz escribi=C3=B3: >=20 > > I have located the bug in /usr/src/contrib/smbfs/lib/smb/subr.c=20 > >=20 > > The printf(3C) calls have been added for debugging; the bug is the > > addition of 13 after crypting every char which let the mask used in ^ o= peration > > exceeding 256, i.e. more than one byte, if the string to be crypted is = long > > enough. The two lines added: > >=20 > > if (pos > 256) > > pos =3D pos-256; > >=20 > > fixes this issue and the crypting/decypting works fine; see below; > >=20 > > I'll later file a PR and propose the patch; =20 >=20 > The PR was already made in 2009: > https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=3D132302 has a patch at= tached (nearly > the same solution as I have found), but was never ci'ed :-( >=20 > matthias >=20 >=20 Wow ... that is, simply ... not very good! :-( High quality! --=20 O. Hartmann Ich widerspreche der Nutzung oder =C3=9Cbermittlung meiner Daten f=C3=BCr Werbezwecke oder f=C3=BCr die Markt- oder Meinungsforschung (=C2=A7 28 Abs.= 4 BDSG). --Sig_/IEq3dtuK6wSBbPAQ_kW830V Content-Type: application/pgp-signature Content-Description: OpenPGP digital signature -----BEGIN PGP SIGNATURE----- iLUEARMKAB0WIQQZVZMzAtwC2T/86TrS528fyFhYlAUCWTg36wAKCRDS528fyFhY lIHBAgCfzFwuQ/UXdq2gVYjnz8rp4zZIlujJVqDHPFgAqGcUbryVAFdMcT3QfJII EMUCFNdc7OYMGAvvGQhBo3CgWPihAf9vDr5h0fWFhKoWP5KBhszOKznai9OFrCqf HxpWLbgIRYumqJ6HN9zcscRA2zl3EuUsRVQufL0cPcMPbahqZy6K =WCxB -----END PGP SIGNATURE----- --Sig_/IEq3dtuK6wSBbPAQ_kW830V--