卷曲';邮政';with XML附件上载在Linux下失败,但在Windows下工作

卷曲';邮政';with XML附件上载在Linux下失败,但在Windows下工作,xml,shell,curl,Xml,Shell,Curl,我一直无法找到在Windows下运行的CURL命令(在Linux中)的问题,但在Linux下运行时失败 您可以在下面看到curl POST命令的成绩单,该命令成功地在Windows下上载了XML文件附件,但出现以下错误: 附加材料未精细转移。c:1037:0 在Linux下运行时 我已经试着把它移走了;命令的contentXml=@部分的type=text/xml后缀,但这没有区别。我还尝试使用Chrome的“inspect元素”来监视HTML表单中的相同内容,但输出表单没有帮助 我觉得我错

我一直无法找到在Windows下运行的CURL命令(在Linux中)的问题,但在Linux下运行时失败

您可以在下面看到curl POST命令的成绩单,该命令成功地在Windows下上载了XML文件附件,但出现以下错误:

  • 附加材料未精细转移。c:1037:0
在Linux下运行时

我已经试着把它移走了;命令的contentXml=@部分的type=text/xml后缀,但这没有区别。我还尝试使用Chrome的“inspect元素”来监视HTML表单中的相同内容,但输出表单没有帮助

我觉得我错过了一件小事(重要的!)。有人对我遗漏的东西有什么建议吗

衷心感谢您的帮助

-----WINDOWS--WORKS--OK------

C:\Users\>curl -k -v -X POST -F "contentName=spotlight" -F "unityRemoteUsername=aaa" -F "unityRemotePassword=aaa" -F " contentXml=@outputSpotlights.xml;type=text/xml" -F "contentXmlFileAction=upload" "https://www.example.com/admin.aspx?a=content.uploadxmlprocess&unityRemoteRequest=1" >log-spotlight_01.txt

* Adding handle: conn: 0x1d6aea0
* Adding handle: send: 0
* Adding handle: recv: 0
* Curl_addHandleToPipeline: length: 1
* - Conn 0 (0x1d6aea0) send_pipe: 1, recv_pipe: 0
  % Total    % Received % Xferd  Average Speed   Time    Time     Time  Current
                                 Dload  Upload   Total   Spent    Left  Speed
  0     0    0     0    0     0      0      0 --:--:-- --:--:-- --:--:--     0*
About to connect() to www.example.com port 443 (#0)
*   Trying 111.222.33.444...
* Connected to www.example.com (111.222.33.444) port 443 (#0)
* SSLv3, TLS handshake, Client hello (1):
} [data not shown]
* SSLv3, TLS handshake, Server hello (2):
{ [data not shown]
* SSLv3, TLS handshake, CERT (11):
{ [data not shown]
* SSLv3, TLS handshake, Server key exchange (12):
{ [data not shown]
* SSLv3, TLS handshake, Server finished (14):
{ [data not shown]
* SSLv3, TLS handshake, Client key exchange (16):
} [data not shown]
* SSLv3, TLS change cipher, Client hello (1):
} [data not shown]
* SSLv3, TLS handshake, Finished (20):
} [data not shown]
* SSLv3, TLS change cipher, Client hello (1):
{ [data not shown]
* SSLv3, TLS handshake, Finished (20):
{ [data not shown]
* SSL connection using DHE-RSA-AES256-SHA
* Server certificate:
*        subject: OU=Domain Control Validated; OU=Hosted by; O
U=COMODO SSL; CN=www.example.com
*        start date: 2013
*        expire date: 2016
*        issuer: C=GB; ST=Greater Manchester; L=Salford; O=COMODO CA Limited; CN
=COMODO RSA Domain Validation Secure Server CA
*        SSL certificate verify result: self signed certificate in certificate c
hain (19), continuing anyway.
> POST /admin.aspx?a=content.uploadxmlprocess&unityRemoteRequest=1 HTTP/1.1
> User-Agent: curl/7.32.0
> Host: www.example.com
> Accept: */*
> Content-Length: 1894
> Expect: 100-continue
> Content-Type: multipart/form-data; boundary=------------------------b4a30d5f4f
02e40b
>
< HTTP/1.1 100 Continue
} [data not shown]
< HTTP/1.1 200 OK
< Cache-Control: private
< Content-Type: text/xml; charset=utf-8
* Server Microsoft-IIS/8.0 is not blacklisted
< Server: Microsoft-IIS/8.0
< Set-Cookie: ASP.NET_SessionId=myp1fxahmvil4p450mlkvy55; path=/; HttpOnly
< X-AspNet-Version: 2.0.50727
< X-Server-Name: www.example.com
< X-Powered-By: ASP.NET
< Date: Fri, 29 Apr 2016 05:01:55 GMT
< Content-Length: 4804
< Set-Cookie: DCW=!YurETMEX+uJDlGsjwPb80U37Lbn8yAZFhJDfC3k/kBCRszzy7sdlEoNLnqW2U
U6om/d+TTG8sc+WQaQ=; path=/
< Vary: Accept-Encoding
<
{ [data not shown]
100  6698  100  4804  100  1894   8798   3468 --:--:-- --:--:-- --:--:--  8798
* Connection #0 to host www.example.com left intact

C:\Users\>




----LINUX---FAILS----

me@LINUX:~/xml/$ curl -k -v -X POST -F "contentName=spotlight" -F "unityRemoteUsername=aaa" -F "unityRemotePassword=bbb" -F "contentXml=@outputSpotlights.xml;type=text/xml" -F "contentXmlFileAction=upload" "https://www.example.com/admin.aspx?a=content.uploadxmlprocess&unityRemoteRequest=1" >log-spotlight_01.txt
* About to connect() to www.example.com port 443 (#0)
*   Trying 111.222.33.444...
  % Total    % Received % Xferd  Average Speed   Time    Time     Time  Current
                                 Dload  Upload   Total   Spent    Left  Speed
  0     0    0     0    0     0      0      0 --:--:-- --:--:-- --:--:--     0* connected
* Connected to www.example.com (111.222.33.444) port 443 (#0)
* successfully set certificate verify locations:
*   CAfile: none
  CApath: /etc/ssl/certs
* SSLv3, TLS handshake, Client hello (1):
} [data not shown]
* SSLv3, TLS handshake, Server hello (2):
{ [data not shown]
* SSLv3, TLS handshake, CERT (11):
{ [data not shown]
* SSLv3, TLS handshake, Server key exchange (12):
{ [data not shown]
* SSLv3, TLS handshake, Server finished (14):
{ [data not shown]
* SSLv3, TLS handshake, Client key exchange (16):
} [data not shown]
* SSLv3, TLS change cipher, Client hello (1):
} [data not shown]
* SSLv3, TLS handshake, Finished (20):
} [data not shown]
* SSLv3, TLS change cipher, Client hello (1):
{ [data not shown]
* SSLv3, TLS handshake, Finished (20):
{ [data not shown]
* SSL connection using DHE-RSA-AES256-GCM-SHA384
* Server certificate:
*        subject: OU=Domain Control Validated; OU=Hosted by ; OU=COMODO SSL; CN=www.example.com
*        start date: 2013
*        expire date: 2016
*        issuer: C=GB; ST=Greater Manchester; L=Salford; O=COMODO CA Limited; CN=COMODO RSA Domain Validation Secure Server CA
*        SSL certificate verify ok.
> POST /admin.aspx?a=content.uploadxmlprocess&unityRemoteRequest=1 HTTP/1.1
> User-Agent: curl/7.26.0
> Host: www.example.com
> Accept: */*
> Content-Length: 1840
> Expect: 100-continue
> Content-Type: multipart/form-data; boundary=----------------------------b59711af552e
>
* additional stuff not fine transfer.c:1037: 0 0
* HTTP 1.1 or later with persistent connection, pipelining supported
< HTTP/1.1 100 Continue
  0  1840    0     0    0     0      0      0 --:--:-- --:--:-- --:--:--     0* additional stuff not fine transfer.c:1037: 0 0
} [data not shown]
* additional stuff not fine transfer.c:1037: 0 0
} [data not shown]
* additional stuff not fine transfer.c:1037: 0 0
} [data not shown]
* additional stuff not fine transfer.c:1037: 0 0
* HTTP 1.1 or later with persistent connection, pipelining supported
< HTTP/1.1 200 OK
< Cache-Control: private
< Content-Type: text/xml; charset=utf-8
< Server: Microsoft-IIS/8.0
< X-AspNet-Version: 2.0.50727
< X-Server-Name: www.example.com
< X-Powered-By: ASP.NET
< Date: Fri, 29 Apr 2016 05:02:22 GMT
< Content-Length: 100
< Set-Cookie: DCW=!QdorcUlrlaR+qA4jwPb80U37Lbn8yDOhcW/oNikxhZm8kVcjfFQuS+kjHbekv0xdGtQM5pDBv2UgMNA=; path=/
<
{ [data not shown]
100  1940  100   100  100  1840    354   6527 --:--:-- --:--:-- --:--:--  7389
* Connection #0 to host www.example.com left intact
* Closing connection #0
* SSLv3, TLS alert, Client hello (1):
} [data not shown]

me@LINUX:~/xml/
----WINDOWS--WORKS--OK------
C:\Users\>curl-k-v-X POST-F“contentName=spotlight”-F“unityremotesername=aaa”-F“unityRemotePassword=aaa”-F“contentXml=@outputpspotlights.xml;type=text/xml”-F“contentXmlFileAction=upload”https://www.example.com/admin.aspx?a=content.uploadxmlprocess&unityRemoteRequest=1“>log-spotlight_01.txt
*正在添加句柄:连接:0x1d6aea0
*正在添加句柄:发送:0
*正在添加句柄:recv:0
*卷曲度加把手尺寸线:长度:1
*-Conn 0(0x1d6aea0)发送管道:1,接收管道:0
%总接收百分比%x平均速度时间电流
数据加载上载总左速度
0     0    0     0    0     0      0      0 --:--:-- --:--:-- --:--:--     0*
即将连接()到www.example.com端口443(#0)
*正在尝试111.222.33.444。。。
*连接到www.example.com(111.222.33.444)端口443(#0)
*SSLv3,TLS握手,客户端hello(1):
}[未显示数据]
*SSLv3,TLS握手,服务器hello(2):
{[未显示数据]
*SSLv3,TLS握手,证书(11):
{[未显示数据]
*SSLv3、TLS握手、服务器密钥交换(12):
{[未显示数据]
*SSLv3,TLS握手,服务器完成(14):
{[未显示数据]
*SSLv3、TLS握手、客户端密钥交换(16):
}[未显示数据]
*SSLv3,TLS更改密码,客户端你好(1):
}[未显示数据]
*SSLv3,TLS握手,完成(20):
}[未显示数据]
*SSLv3,TLS更改密码,客户端你好(1):
{[未显示数据]
*SSLv3,TLS握手,完成(20):
{[未显示数据]
*使用DHE-RSA-AES256-SHA的SSL连接
*服务器证书:
*主题:OU=已验证的域控制;OU=托管者;O
U=COMODO SSL;CN=www.example.com
*开始日期:2013年
*有效期:2016年
*发行人:C=GB;ST=Greater Manchester;L=Salford;O=COMODO CA Limited;CN
=COMODO RSA域验证安全服务器CA
*SSL证书验证结果:证书c中的自签名证书
海恩(19岁),无论如何继续。
>POST/admin.aspx?a=content.uploadxmlprocess&unityRemoteRequest=1http/1.1
>用户代理:curl/7.32.0
>主持人:www.example.com
>接受:*/*
>内容长度:1894
>预期:100人继续
>内容类型:多部分/表单数据;边界=---------------------------b4a30d5f4f
02e40b
>

----LINUX——失败----
me@LINUX:~/xml/$curl-k-v-X POST-F“contentName=spotlight”-F“unityremotesername=aaa”-F“unityRemotePassword=bbb”-F“contentXml=@outputspottlights.xml;type=text/xml”-F“contentXmlFileAction=upload”https://www.example.com/admin.aspx?a=content.uploadxmlprocess&unityRemoteRequest=1“>log-spotlight_01.txt
*即将连接()到www.example.com端口443(#0)
*正在尝试111.222.33.444。。。
%总接收百分比%x平均速度时间电流
数据加载上载总左速度
0 0 0 0 0 0 0--:-:-:-:---:-:---:---:---0*已连接
*连接到www.example.com(111.222.33.444)端口443(#0)
*已成功设置证书验证位置:
*卡菲尔:没有
CApath:/etc/ssl/certs
*SSLv3,TLS握手,客户端hello(1):
}[未显示数据]
*SSLv3,TLS握手,服务器hello(2):
{[未显示数据]
*SSLv3,TLS握手,证书(11):
{[未显示数据]
*SSLv3、TLS握手、服务器密钥交换(12):
{[未显示数据]
*SSLv3,TLS握手,服务器完成(14):
{[未显示数据]
*SSLv3、TLS握手、客户端密钥交换(16):
}[未显示数据]
*SSLv3,TLS更改密码,客户端你好(1):
}[未显示数据]
*SSLv3,TLS握手,完成(20):
}[未显示数据]
*SSLv3,TLS更改密码,客户端你好(1):
{[未显示数据]
*SSLv3,TLS握手,完成(20):
{[未显示数据]
*使用DHE-RSA-AES256-GCM-SHA384的SSL连接
*服务器证书:
*主题:OU=域控制已验证;OU=托管者;OU=COMODO SSL;CN=www.example.com
*开始日期:2013年
*有效期:2016年
*发卡机构:C=GB;ST=Greater Manchester;L=Salford;O=COMODO CA Limited;CN=COMODO RSA域验证安全服务器CA
*SSL证书验证正常。
>POST/admin.aspx?a=content.uploadxmlprocess&unityRemoteRequest=1http/1.1
>用户代理:curl/7.26.0
>主持人:www.example.com
>接受:*/*
>内容长度:1840
>预期:100人继续
>内容类型:多部分/表单数据;边界=------------------------------------B5971AF552E
>
*附加材料不可精细转移。c:1037: