delorie.com/archives/browse.cgi   search  
Mail Archives: cygwin/2022/07/13/03:42:14

X-Recipient: archive-cygwin AT delorie DOT com
X-Original-To: cygwin AT cygwin DOT com
Delivered-To: cygwin AT cygwin DOT com
DMARC-Filter: OpenDMARC Filter v1.4.1 sourceware.org 65F18385829D
Authentication-Results: sourceware.org;
dmarc=pass (p=none dis=none) header.from=fujitsu.com
Authentication-Results: sourceware.org; spf=pass smtp.mailfrom=fujitsu.com
DKIM-Signature: v=1; a=rsa-sha256; c=simple/simple;
d=fujitsu.com; i=@fujitsu.com; q=dns/txt; s=fj1;
t=1657698093; x=1689234093;
h=from:to:cc:subject:date:message-id:
content-transfer-encoding:mime-version;
bh=SwhaeGcALY7IjVwvH10neODcY0DoFTRvHD07eauMPc4=;
b=qNIK6WQ7Us47aPzQBcQWXJtmBG6m0+2/T44IUlJqJVd8Z3xKnkHU6LPe
GNK3gnVIMD1OabJd+bHrvJuvRNY1UFeRO8/KIDPJ7bHc6xdGg9mAGs9GD
hsKT8now4gyxU9zKqMj7M6Klqee4AxNVDw2Z9ud/tk5XOoCSCTDJPZsIu
2VMLIGzHg1BN9WoF88BuY9wXm5U9shRkGO2+8mcgUXWD/RCJgTXATe7rj
KddGc8yUxmWZp92URnrPDN7I92iru9Veu6go5z+U6memtqLRINCCpf2EX
hImysia6A5iFRZ84F/fJK4gSi8/MQulekcmJxzwopU4aGurlxbleINQ0R A==;
X-IronPort-AV: E=McAfee;i="6400,9594,10406"; a="68536426"
X-IronPort-AV: E=Sophos;i="5.92,267,1650898800"; d="scan'208";a="68536426"
ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none;
b=lBaqLFL8GdYqD4mT1vORznKhsv28up1Dv7GjOdGAYlhoVkJjsti+gEAHqxvQq966pGf24UGto16VeoiCjfpKRFnlk5IEFjpCClL1tAghJdD5RJpNGq7gIJdKwFpFWmMABkrKk7MBf80r5nJBTyGVzcXg4TDxg8H4JBG5TGxHxhZWw5wy8zBnTIoHrFrYze/taU3UENzgnBbvHqMIqA9bJMU69lxbFCsZ8MSg9+HJ0CtrNFZSrhkETCRpHTkJ4tcqvwl8ipItCl2l7D6tTAK90MJ1vUOZ6bAXb0eNKrNSje0TTkEw5ZqI9D7A15qTaaloCUFBg6l1tMwr/qF3bM9hVw==
ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com;
s=arcselector9901;
h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-AntiSpam-MessageData-ChunkCount:X-MS-Exchange-AntiSpam-MessageData-0:X-MS-Exchange-AntiSpam-MessageData-1;
bh=dLQvamxKwjMThlw1tnimBBWrKrC9CHjkZRCGrEeDIrU=;
b=YlUmdIeX0Om37AmrK3ndu0aUbWgPXZtuRFqIPhsspanMqzMiEV1PCMBzfJYvt0kwk7FZeXeTpKXgdlngDUyrreAnLZtj8pNgh8glSR9HJ0mMjE2+rDITS9if7RnSredVM7DbXBk+UJVrZeNHblYJ8uEFBZvYJuh+575F/JYTBb1weJPy4gnvqagupXZ5fKbg+Tc9bB4LmxnQcWIntYzFgqUMHiHY+qiw0OX2/n+EZtN3ek+EDNY+YNO0aXXPjIRi7o45gVmZm8o5M/dStV+y391O6CmyGXxYXq0j43qHxxx6PU25umOtDk/6irHxKTAiLLEe4X/F8woBP+wJgZMLNQ==
ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=pass
smtp.mailfrom=fujitsu.com; dmarc=pass action=none header.from=fujitsu.com;
dkim=pass header.d=fujitsu.com; arc=none
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed;
d=fujitsu.onmicrosoft.com; s=selector2-fujitsu-onmicrosoft-com;
h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck;
bh=dLQvamxKwjMThlw1tnimBBWrKrC9CHjkZRCGrEeDIrU=;
b=YYKUZ2lyyfJ6Fupb3wVZ95lizbSlFnoKm02Mwv6btLYM+wdVmDX2kv2lyB9dxExwIjWaDhHn+bT64XpEqfHir6F7+1inXzqRICKYZ+iVr1NqUvQnyW8LsPckndV0iiD5idON1TLmpwsMqkmnooWXx5fwk/RRq0xUsmh71RhQdfs=
From: "suzuki DOT masaomi AT fujitsu DOT com" <suzuki DOT masaomi AT fujitsu DOT com>
To: "'cygwin AT cygwin DOT com'" <cygwin AT cygwin DOT com>
Subject: scp command fails to transfer file and returns 1.
Thread-Topic: scp command fails to transfer file and returns 1.
Thread-Index: AdiWi62jVeXnF3ElTvSG79UO+L3cGg==
Date: Wed, 13 Jul 2022 07:41:25 +0000
Message-ID: <TYCPR01MB6818607796F45A8DB98EF21B87899@TYCPR01MB6818.jpnprd01.prod.outlook.com>
Accept-Language: ja-JP, en-US
X-MS-Has-Attach:
X-MS-TNEF-Correlator:
msip_labels: MSIP_Label_a7295cc1-d279-42ac-ab4d-3b0f4fece050_Enabled=true;
MSIP_Label_a7295cc1-d279-42ac-ab4d-3b0f4fece050_SetDate=2022-07-13T07:38:52Z;
MSIP_Label_a7295cc1-d279-42ac-ab4d-3b0f4fece050_Method=Standard;
MSIP_Label_a7295cc1-d279-42ac-ab4d-3b0f4fece050_Name=FUJITSU-RESTRICTED?;
MSIP_Label_a7295cc1-d279-42ac-ab4d-3b0f4fece050_SiteId=a19f121d-81e1-4858-a9d8-736e267fd4c7;
MSIP_Label_a7295cc1-d279-42ac-ab4d-3b0f4fece050_ActionId=fe0db9cf-e507-43a1-ab15-ea148881b416;
MSIP_Label_a7295cc1-d279-42ac-ab4d-3b0f4fece050_ContentBits=0
x-securitypolicycheck: OK by SHieldMailChecker v2.6.5
x-shieldmailcheckermailid: e14fdc0c876240be82f01e0d444ba04e
authentication-results: dkim=none (message not signed)
header.d=none;dmarc=none action=none header.from=fujitsu.com;
x-ms-publictraffictype: Email
x-ms-office365-filtering-correlation-id: 449901a7-9720-4866-c77d-08da64a316ea
x-ms-traffictypediagnostic: OSAPR01MB3777:EE_
x-ms-exchange-senderadcheck: 1
x-ms-exchange-antispam-relay: 0
x-microsoft-antispam: BCL:0;
x-microsoft-antispam-message-info: eFSoUCF8vu0DUmQlNUDPzmNKOUDpYgujazpKFRlUMTT5AFxG0GcFCRifM8Gv92DT7MUrz8e0nskDIJ8z/PHUPwUP1T0y0ChrIHKxOM0/FFu4drOarp/1jb9sdRwT2iUjBYOgqK96RxJOSxf3QtcwwdOglE48bzp/a16yTWv7BkWEg6CzIl+F/DWkPNdmI0Jt4+gAoc3wVrT3ZL9knnZdqsZuwVpGdnrR0WxV/NhLkhCSylmdo0xvvxNPgS54lRACm7wCFOhd/snqnUw4ijOjSrubMg6o5xCrg4SPo6QMc2a/yIoQ1so8fUhFNOCjYX79h9QOrk8P4d1u6snOOnlyv/Am3cp6A7pJlNqQjCtl4SWEaGdnpwAbC9Lt20UZkuTkOsQG4YP0CD8RuyZuLwOwT/sSs4W/ifZcR+E8mN7Vf3qR7BDJKTTMTERu1CaBzU77E9eKHwLxIZNmrr8BajA5lBAvUEEkuUokwia1FBjn4TcJ+pdhB9sGQdSk6W0r738mzCjShmqbfME8ZLO3KZmdObnCoIi/JB3rz0lSndpDhyFIjSS/7cgLEN0SB2QXNEMZi8wzG5CsqEpTkeRrUxgRp5m77d5R7f+q3Z750cu/Lqocb9BCfXsV2P1chS+JiXmYnMGiUxYbeL/TIY1sIX49vpRYS4Ka3VbxZ3nvEwlEjyDJfXwsKGP/pRjl4SrebPl/mmRSvrjwIs96NkF81l+SnCzuWdbpeVzSS8YMaDhAkbkUm3c0t8QfCoC9ktREl6FyrecVruYuvvSNfd1MS4owA4VzVUxPwASHBGF8XBPrvpegJ0vtXtKrC6xPOq2266Nm/Oxqac79zbXcSXbpLXzHpu08T1dGwYWdlEgOpRkjg5RmysYNWW3Z1iWFtsAeSK5pmI0EbnS1TJSZ+NvnfQ36Zg==
x-forefront-antispam-report: CIP:255.255.255.255; CTRY:; LANG:ja; SCL:1; SRV:;
IPV:NLI; SFV:NSPM; H:TYCPR01MB6818.jpnprd01.prod.outlook.com; PTR:; CAT:NONE;
SFS:(13230016)(4636009)(396003)(346002)(39860400002)(136003)(366004)(376002)(85182001)(55016003)(52536014)(8936002)(26005)(41300700001)(38100700002)(316002)(33656002)(2906002)(83380400001)(5660300002)(122000001)(66946007)(66476007)(82960400001)(86362001)(6506007)(186003)(9686003)(76116006)(7696005)(66556008)(66446008)(64756008)(66574015)(107886003)(38070700005)(478600001)(4326008)(71200400001)(6916009)(8676002)(491001)(460985005);
DIR:OUT; SFP:1101;
x-ms-exchange-antispam-messagedata-chunkcount: 1
x-ms-exchange-antispam-messagedata-0: =?iso-2022-jp?B?RUVxa2dCVG04YUdZUTB3T3hTcERzWE8zbFNlRmJmajZEWkJIQy9ML1Nq?=
=?iso-2022-jp?B?RmxWTnNrdmpBNkhoNGFvUS9uanVjK3BnQzhUZGdtUmpoclFuSi9ERGRk?=
=?iso-2022-jp?B?UFNFZnZnWXV0aGdWN2VpcDhScldYc3hhQk1hRUIxWkd0Nk5obDhKS0lI?=
=?iso-2022-jp?B?UkRFWU9NVjJUb3l4QldydlJOam45Y3prR1JrQWpMSHJZTFh4K0FaT1Vj?=
=?iso-2022-jp?B?SUhiUTZzSEwrbHA4S0FORnlFZXFaeEQ0dm5MOVQ1VFgrUE5NNkgrNGhy?=
=?iso-2022-jp?B?NUxTbDE3VUI2dm9BNlRjS3VleGZlVEU1b1NiRzVSb1VXWWlPYzlndXBz?=
=?iso-2022-jp?B?ZGUrUVU5bDFzNnpxQ2loQWNVd1ZRUjRqOWVwQlI1MThqbG55dGgyak5L?=
=?iso-2022-jp?B?SFNsKzhqZDVSd1lqcVJLbjQrQzQ4WFphUi9UNW5zcnFsTnQwc2VrWGF3?=
=?iso-2022-jp?B?RmZhWTAwZThyTTdMN3VNemVVcXgvaGFTcG0yTWxkdk02ZGl5eWVxRTU0?=
=?iso-2022-jp?B?R3dNUFR5NHUzNUJFUzVlY3RnUTRtZG9Nckw2U0g2Nk9MMG5DSGtnWDhD?=
=?iso-2022-jp?B?Sm96NmF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S-Exchange-CrossTenant-AuthAs: Internal
X-MS-Exchange-CrossTenant-AuthSource: TYCPR01MB6818.jpnprd01.prod.outlook.com
X-MS-Exchange-CrossTenant-Network-Message-Id: 449901a7-9720-4866-c77d-08da64a316ea
X-MS-Exchange-CrossTenant-originalarrivaltime: 13 Jul 2022 07:41:25.2653 (UTC)
X-MS-Exchange-CrossTenant-fromentityheader: Hosted
X-MS-Exchange-CrossTenant-id: a19f121d-81e1-4858-a9d8-736e267fd4c7
X-MS-Exchange-CrossTenant-mailboxtype: HOSTED
X-MS-Exchange-CrossTenant-userprincipalname: rL66uCtnom+PaefivWqMAJl94O8StIG3uxoXhoECsAjNZm/QORcYvuCkYUaByMpqo+MA2pBViE6mYTuBwy42m+vVmdj6d/ISNV2xbLtK2ic=
X-MS-Exchange-Transport-CrossTenantHeadersStamped: OSAPR01MB3777
X-Spam-Status: No, score=0.8 required=5.0 tests=BAYES_50, DKIM_SIGNED,
DKIM_VALID, KAM_DMARC_NONE, RCVD_IN_MSPIKE_H2, SPF_HELO_PASS, SPF_NONE, TXREP,
T_SCC_BODY_TEXT_LINE,
WEIRD_QUOTING autolearn=no autolearn_force=no version=3.4.6
X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on
server2.sourceware.org
X-BeenThere: cygwin AT cygwin DOT com
X-Mailman-Version: 2.1.29
List-Id: General Cygwin discussions and problem reports <cygwin.cygwin.com>
List-Archive: <https://cygwin.com/pipermail/cygwin/>
List-Post: <mailto:cygwin AT cygwin DOT com>
List-Help: <mailto:cygwin-request AT cygwin DOT com?subject=help>
List-Subscribe: <https://cygwin.com/mailman/listinfo/cygwin>,
<mailto:cygwin-request AT cygwin DOT com?subject=subscribe>
Cc: "'soft-mpop-qqm AT ml DOT css DOT fujitsu DOT com'" <soft-mpop-qqm AT ml DOT css DOT fujitsu DOT com>
Sender: "Cygwin" <cygwin-bounces+archive-cygwin=delorie DOT com AT cygwin DOT com>

Cygwin$B%5%]!<%H(B $B$4C4EvMM(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failed to upload file /cygdrive//C/test/a to "/tmp/a"

$B"#LdBj$NJdB-(B
$B!!!&(Bscp$B%3%^%s%I$r!"EvJ}$N%"%W%j%1!<%7%g%s%W%m%0%i%`$+$i;R%W%m%;%9$H$7$F(B
$B!!!!<B9T$9$k$N$G$O$J$/!"%3%^%s%I%W%m%s%W%H$d(BCygwin Bash Shell$B$+$iD>@\E*$K(B
$B!!!!<B9T$7$?>l9g$O!"La$jCM(B"0"$B$GI|5"$7!"%U%!%$%kE>Aw$O AT  DOT 8y$7$^$9!#(B

$B!!!&5l%P!<%8%g%s(B(3.2.0)$B$N(BCygwin$B$rF1$8(BOS$B$KF3F~$7$?8e!"(B
$B!!!!EvJ}$N%"%W%j%1!<%7%g%s%W%m%0%i%`$r<B9T$7$?>l9g$O!"(Bscp$B%3%^%s%I$O(B
$B!!!!La$jCM(B"0"$B$GI|5"$7!"%U%!%$%kE>Aw$O AT  DOT 8y$7$^$9!#(B

$B!!0J>e$N$3$H$+$i!"2f!9$O!":G?7%P!<%8%g%s(B(3.3.5)$B$H5l%P!<%8%g%s(B(3.2.0)$B$N(B
$B!!(BCygwin$B$G!"(Bscp$B%3%^%s%I$NF0:n;EMM$K2?$i$+$NHs8_49$,$"$k$N$G$O$J$$$+!"$H(B
$B!!?dB,$7$F$$$^$9!#(B

$B"#0MMj;v9`(B
$B!!>e5-$NLdBj$KBP$7$F!"9M$($i$l$k860x$*$h$SBP=hJ}K!$O$"$j$^$9$+!)(B

  $B!c2sEz AT h!d(B
$B!!!!(Bsoft-mpop-qqm AT ml DOT css DOT fujitsu DOT com

$B"#EvJ}$N%"%W%j%1!<%7%g%s%W%m%0%i%`(B
$B!!!&;R%W%m%;%9$N<B9TJ}K!(B
$B!!!!(BWindows API$B$N(BCreateProcess()$B$r0J2<$NMM$K;HMQ$7!";R%W%m%;%9$r<B9T$7$^$9!#(B

 $B!!(BCreateProcess(NULL, 
        fullPathCmd,$B!!!!(B/* ssh,scp$B$N(Bcommond line                     */
        NULL,           /* process security attributes              */
        NULL,           /* primary thread security attributes       */
        TRUE,           /* handles are inherited                    */
        NORMAL_PRIORITY_CLASS|CREATE_NO_WINDOW,  /* creation flags  */
        NULL,           /* use parent's environment                 */
        NULL,           /* use parent's current directory           */
        &si,            /* STARTUPINFO pointer                      */
        &pi);           /* receives PROCESS_INFORMATION             */

$B!!!&(Bssh$B%3%^%s%I$r<B9T$9$k;~$N%3%^%s%I%i%$%s(B
$B!!!!>e5-$K<($7$?(BCreateProcess()$B$NBh#2%Q%i%a%?(BfullPathCmd$B$r!"0J2<$NMM$K(B
$B!!!!;XDj$7$F$$$^$9!#(B

$B!!!!(B<Cygwin$B$N%$%s%9%H!<%k%G%#%l%/%H%j(B>\bin\ssh.exe -q -l root -p 22 $B%[%9%HL>(B "echo aaa && /bin/sh -c \"/bin/uname -n\""

$B!!!&(Bscp$B%3%^%s%I$r<B9T$9$k;~$N%3%^%s%I%i%$%s(B
$B!!!!>e5-$K<($7$?(BCreateProcess()$B$NBh#2%Q%i%a%?(BfullPathCmd$B$r!"0J2<$NMM$K(B
$B!!!!;XDj$7$F$$$^$9!#(B
$B!!!!(B
$B!!!!(B<Cygwin$B$N%$%s%9%H!<%k%G%#%l%/%H%j(B>\bin\scp.exe "/cygdrive//C/test/a" "root"@$B%[%9%HL>(B:""/tmp/a""


$B0J>e!"$h$m$7$/$*4j$$$7$^$9!#(B


$B0J9_$O1QLuJ8>O$G$9!#(B
******************************************************************
Cygwin Support Dear Representatives

Thank you for your support.
I am Shen Ting.

We ask for your cooperation in solving the following problem.

$B"#(BEnvironment
  OS: Windows Server 2019
$B!!(BCygwin Version : 3.3.5

$B"#(BBackground of the problem
In our application program, for the purpose of SSH communication and file transfer to a remote system (OS: Linux), 
the ssh and scp commands included in Cygwin are executed as child processes.
(*) For details of the demonstration contents, refer to "$B"#(BOur Application Program"
(*)As a preliminary preparation, we set the SSH public key and 
   confirm that we can connect to SSH without inquiring about the password.

$B"#(BThe problem
In the OS, after installing the latest version (3.3.5) of Cygwin downloaded from the URL(https://www.cygwin.com/), 
when we execute our application program, the scp command returns "1" every time, and the file transfer fails.

As a result of debugging our application program, the scp command returned the following message.

$B!!(B/usr/bin/scp: dest open ""/tmp/a"": No such file or directory
$B!!(B/usr/bin/scp: failed to upload file /cygdrive//C/test/a to "/tmp/a"

$B"#(BProblem supplement
$B!&(BIf the scp command is executed directly from the command prompt or Cygwin Bash Shell
  instead of being executed from our application program as a child process, 
  "0" will be returned and the file transfer will succeed.

$B!&(BIf we execute our application program after introducing the old version Cygwin(3.2.0) to the same OS, 
  the scp command will return "0" and the file transfer will be successful.

From the above, we speculate that there may be some incompatibility in the operating specifications of 
the scp command in the latest version Cygwin(3.3.5) and the old version Cygwin(3.2.0).

$B"#(BRequests
  Are there any possible causes and workarounds for the above problem?

  <Respondents>
   soft-mpop-qqm AT ml DOT css DOT fujitsu DOT com

$B"#(BOur Application Program
$B!&(BHow child processes run
  Use the Windows API CreateProcess() as follows to execute the child process.

 $B!!(BCreateProcess(NULL, 
        fullPathCmd,$B!!!!(B/* ssh,scp$B$N(Bcommond line                    */
        NULL,           /* process security attributes              */
        NULL,           /* primary thread security attributes       */
        TRUE,           /* handles are inherited                    */
        NORMAL_PRIORITY_CLASS|CREATE_NO_WINDOW,  /* creation flags  */
        NULL,           /* use parent's environment                 */
        NULL,           /* use parent's current directory           */
        &si,            /* STARTUPINFO pointer                      */
        &pi);           /* receives PROCESS_INFORMATION             */

$B!&(BCommand line when executing ssh command
  The second parameter of CreateProcess() shown above, fullPathCmd, is specified as follows.
 
   <Cygwin Installation Directory>\bin\ssh.exe -q -l root -p 22 $B%[%9%HL>(B "echo aaa && /bin/sh -c \"/bin/uname -n\""

$B!&(BCommand line when executing scp command
  The second parameter of CreateProcess() shown above, fullPathCmd, is specified as follows.
 
   <Cygwin Installation Directory>\bin\scp.exe "/cygdrive//C/test/a" "root"@$B%[%9%HL>(B:""/tmp/a""

******************************************************************

-- 
Problem reports:      https://cygwin.com/problems.html
FAQ:                  https://cygwin.com/faq/
Documentation:        https://cygwin.com/docs.html
Unsubscribe info:     https://cygwin.com/ml/#unsubscribe-simple

- Raw text -


  webmaster     delorie software   privacy  
  Copyright © 2019   by DJ Delorie     Updated Jul 2019