git.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Pascal Obry <pascal@obry.net>
To: git list <git@vger.kernel.org>
Subject: [PATCH] Do not scramble password read from .cvspass
Date: Fri, 04 Sep 2009 13:58:32 +0200	[thread overview]
Message-ID: <4AA100E8.9030806@obry.net> (raw)


Passwords stored in .cvspass are already scrambled, we do not
want to scramble them twice. Only passwords read from the
command line are scrambled.

This fixes a regression introduced by:
b2139dbd72d16e40eddfd5b9ad1314703b39fe65

Signed-off-by: Pascal Obry <pascal@obry.net>
---
  git-cvsimport.perl |    7 ++++---
  1 files changed, 4 insertions(+), 3 deletions(-)

diff --git a/git-cvsimport.perl b/git-cvsimport.perl
index 593832d..c5cdcae 100755
--- a/git-cvsimport.perl
+++ b/git-cvsimport.perl
@@ -238,7 +238,10 @@ sub conn {
                 }
                 my $rr = ":pserver:$user\@$serv:$port$repo";

-               unless ($pass) {
+               if ($pass) {
+                   $pass = $self->_scramble($pass);
+               } else
+               {
                         open(H,$ENV{'HOME'}."/.cvspass") and do {
                                 # 
:pserver:cvs@mea.tmt.tele.fi:/cvsroot/zmailer Ah<Z
                                 while (<H>) {
@@ -253,8 +256,6 @@ sub conn {
                         };
                 }

-               $pass = $self->_scramble($pass);
-
                 my ($s, $rep);
                 if ($proxyhost) {

--
1.6.4.2.253.g0b1fac


-- 

--|------------------------------------------------------
--| Pascal Obry                           Team-Ada Member
--| 45, rue Gabriel Peri - 78114 Magny Les Hameaux FRANCE
--|------------------------------------------------------
--|    http://www.obry.net  -  http://v2p.fr.eu.org
--| "The best way to travel is by means of imagination"
--|
--| gpg --keyserver keys.gnupg.net --recv-key F949BD3B

             reply	other threads:[~2009-09-04 11:58 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2009-09-04 11:58 Pascal Obry [this message]
2009-09-04 16:21 ` [PATCH] Do not scramble password read from .cvspass Junio C Hamano
2009-09-07 10:39   ` Dirk Hörner

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=4AA100E8.9030806@obry.net \
    --to=pascal@obry.net \
    --cc=git@vger.kernel.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).