我怎样才能得到这个回复? (Guzzle,请求http / xml)

时间:2017-10-11 07:22:48

标签: php http networking guzzle packet

我使用wireshark捕获数据包。

因为我想从网站上得到直接回复。

但是,我无法使用Guzzle(PHP)获得响应。

如何使用Guzzle获得回复。如果还有其他选择,请给我一个建议。

这是请求包

Hypertext Transfer Protocol
POST /EleBidNotice.do HTTP/1.1\r\n
    [Expert Info (Chat/Sequence): POST /EleBidNotice.do HTTP/1.1\r\n]
    Request Method: POST
    Request URI: /EleBidNotice.do
    Request Version: HTTP/1.1
Accept: */*\r\n
Cache-Control: no-cache\r\n
Connection: close\r\n
User-Agent: MiPlatform 3.2;win32;1920x1200\r\n
Accept-Charset: utf-8\r\n
Accept-Language: ko-KR\r\n
Host: ebid.airport.kr\r\n
Content-Length: 982\r\n
    [Content length: 982]
 [truncated]Cookie: EBID_SESSION=zcbHfDvsKpcnTzQE1Caj0d51S9V3NFLhyyFTuVvg7FiaszsV9ok2GW1VRTpf5QDX.aebdapp1_servlet_EBID2; GV_JSESSIONID=; HttpOnly=; JSESSIONID=zcbHfDvsKpcnTzQE1Caj0d51S9V3NFLhyyFTuVvg7FiaszsV9ok2GW1VRTpf5QDX.aebdapp1_servl
    Cookie pair: EBID_SESSION=zcbHfDvsKpcnTzQE1Caj0d51S9V3NFLhyyFTuVvg7FiaszsV9ok2GW1VRTpf5QDX.aebdapp1_servlet_EBID2
    Cookie pair: GV_JSESSIONID=
    Cookie pair: HttpOnly=
    Cookie pair: JSESSIONID=zcbHfDvsKpcnTzQE1Caj0d51S9V3NFLhyyFTuVvg7FiaszsV9ok2GW1VRTpf5QDX.aebdapp1_servlet_EBID2
    Cookie pair: Path=/
    Cookie pair: PHAROSVISITOR=0009b04c015f093d18585543ac117320
Content-Type: text/xml;charset=utf-8\r\n
\r\n
[Full request URI: http://ebid.airport.kr/EleBidNotice.do]
[HTTP request 1/1]
[Response in frame: 167]
File Data: 982 bytes
eXtensible Markup Language
<?xml
    version="1.0"
    encoding="utf-8"
    ?>
<root>
    <params>
        <param
            id="bdNtcBase"
            type="STRING">
            </param>
        <param
            id="bdNtcNm"
            type="STRING">
            </param>
        <param
            id="bdStat"
            type="STRING">
            </param>
        <param
            id="beanName"
            type="STRING">
            EleBidNotice
            </param>
        <param
            id="EBID_SESSION"
            type="STRING">
            zcbHfDvsKpcnTzQE1Caj0d51S9V3NFLhyyFTuVvg7FiaszsV9ok2GW1VRTpf5QDX.aebdapp1_servlet_EBID2
            </param>
        <param
            id="GV_JSESSIONID"
            type="STRING">
            </param>
        <param
            id="HttpOnly"
            type="STRING">
            </param>
        <param
            id="inputVOName"
            type="STRING">
            com.iiac.auri.ebid.eb.impl.EleBidNoticeSVO
            </param>
        <param
            id="JSESSIONID"
            type="STRING">
            zcbHfDvsKpcnTzQE1Caj0d51S9V3NFLhyyFTuVvg7FiaszsV9ok2GW1VRTpf5QDX.aebdapp1_servlet_EBID2
            </param>
        <param
            id="menuId"
            type="STRING">
            </param>
        <param
            id="methodName"
            type="STRING">
            selectNoticeVenList
            </param>
        <param
            id="Path"
            type="STRING">
            /
            </param>
        <param
            id="PHAROSVISITOR"
            type="STRING">
            0009b04c015f093d18585543ac117320
            </param>
        </params>
    </root>

这是响应包

Hypertext Transfer Protocol
HTTP/1.1 200 OK\r\n
    [Expert Info (Chat/Sequence): HTTP/1.1 200 OK\r\n]
    Request Version: HTTP/1.1
    Status Code: 200
    [Status Code Description: OK]
    Response Phrase: OK
Date: Wed, 11 Oct 2017 06:54:33 GMT\r\n
Content-Type: application/octet-stream\r\n
Connection: close\r\n
Transfer-Encoding: chunked\r\n
\r\n
[HTTP response 1/1]
[Time since request: 0.048185000 seconds]
[Request in frame: 157]
HTTP chunked response
    Data chunk (7816 octets)
        Chunk size: 7816 octets
        Data (7816 bytes)
            Data: 0002fe100fa000c9000b000862644e7463436e7400000008...
            [Length: 7816]
        Chunk boundary: 0d0a
    End of chunked encoding
        Chunk size: 0 octets
    \r\n
File Data: 7816 bytes
Media Type
Media type: application/octet-stream (7816 bytes)


0000   00 02 fe 10 0f a0 00 c9 00 0b 00 08 62 64 4e 74  ............bdNt
0010   63 43 6e 74 00 00 00 08 6d 69 6e 64 43 6f 64 65  cCnt....mindCode
0020   00 00 00 07 62 64 4e 74 63 4e 6d 00 08 00 00 00  ....bdNtcNm.....
0030   06 62 64 53 74 61 74 00 08 00 00 00 06 75 73 65  .bdStat......use
0040   72 49 64 00 00 00 08 62 64 4e 74 63 44 74 53 00  rId....bdNtcDtS.
0050   00 00 1f 43 4f 4c 55 4d 4e 5f 49 4e 46 4f 5f 46  ...COLUMN_INFO_F
0060   4f 52 5f 65 6c 65 42 69 64 4e 6f 74 69 63 65 44  OR_eleBidNoticeD
0070   56 4f 00 08 00 2a 63 6f 6d 2e 69 69 61 63 2e 61  VO...*com.iiac.a
0080   75 72 69 2e 65 62 69 64 2e 65 62 2e 69 6d 70 6c  uri.ebid.eb.impl
0090   2e 45 6c 65 42 69 64 4e 6f 74 69 63 65 44 56 4f  .EleBidNoticeDVO
00a0   00 09 62 64 4e 74 63 42 61 73 65 00 08 00 00 00  ..bdNtcBase.....
00b0   08 62 64 4e 74 63 44 74 45 00 00 00 08 62 64 4e  .bdNtcDtE....bdN
00c0   74 63 4e 75 6d 00 00 00 06 76 65 6e 53 65 71 00  tcNum....venSeq.
00d0   00 fe 01 0f a0 03 9a 00 0f 65 6c 65 42 69 64 4e  .........eleBidN
00e0   6f 74 69 63 65 44 56 4f fe 10 0f a0 00 02 00 00  oticeDVO........
00f0   00 36 00 09 62 64 50 72 6f 63 45 64 74 00 01 00  .6..bdProcEdt...
0100   ff 00 01 00 06 74 65 6e 64 65 72 00 01 00 ff 00  .....tender.....
0110   01 00 06 62 64 53 74 61 74 00 01 00 ff 00 01 00  ...bdStat.......
0120   08 62 64 52 65 61 6c 4e 6d 00 01 00 ff 00 01 00  .bdRealNm.......
0130   06 72 65 63 53 64 74 00 01 00 ff 00 01 00 0c 65  .recSdt........e
0140   76 61 6c 43 6f 6d 6d 4d 75 6c 74 00 01 00 ff 00  valCommMult.....
0150   01 00 06 63 6f 6e 43 6e 74 00 01 00 ff 00 01 00  ...conCnt.......
0160   0d 62 64 4e 74 63 50 72 6f 63 54 79 70 65 00 01  .bdNtcProcType..
0170   00 ff 00 01 00 07 62 64 52 74 6f 59 6e 00 01 00  ......bdRtoYn...
0180   ff 00 01 00 05 61 73 43 6e 74 00 01 00 ff 00 01  .....asCnt......
0190   00 08 62 64 42 69 64 53 64 74 00 01 00 ff 00 01  ..bdBidSdt......
01a0   00 06 74 65 61 6d 59 6e 00 01 00 ff 00 01 00 0c  ..teamYn........
01b0   73 65 74 74 6c 65 53 74 61 74 4e 6d 00 01 00 ff  settleStatNm....
01c0   00 01 00 0e 62 64 4e 74 63 50 72 6f 63 42 69 64  ....bdNtcProcBid
01d0   4e 6d 00 01 00 ff 00 01 00 0b 62 64 4e 74 63 54  Nm........bdNtcT
01e0   79 70 65 4e 6d 00 01 00 ff 00 01 00 09 62 64 50  ypeNm........bdP
01f0   72 6f 63 53 64 74 00 01 00 ff 00 01 00 05 70 72  rocSdt........pr
0200   4e 75 6d 00 01 00 ff 00 01 00 08 6d 69 6e 64 45  Num........mindE
0210   76 61 6c 00 01 00 ff 00 01 00 08 62 64 4e 74 63  val........bdNtc
0220   43 6e 74 00 04 00 ff 00 01 00 07 62 64 47 62 6e  Cnt........bdGbn
0230   4e 6d 00 01 00 ff 00 01 00 08 62 64 46 69 6e 67  Nm........bdFing
0240   65 72 00 01 00 ff 00 01 00 0c 64 65 6d 61 6e 64  er........demand
0250   44 65 70 74 4e 6d 00 01 00 ff 00 01 00 08 62 64  DeptNm........bd
0260   53 74 61 74 4e 6d 00 01 00 ff 00 01 00 07 62 64  StatNm........bd
0270   4e 74 63 4e 6d 00 01 00 ff 00 01 00 08 62 64 4e  NtcNm........bdN
0280   6f 74 69 59 6e 00 01 00 ff 00 01 00 0a 73 65 74  otiYn........set
0290   74 6c 65 53 74 61 74 00 01 00 ff 00 01 00 09 62  tleStat........b
02a0   64 4e 74 63 54 79 70 65 00 01 00 ff 00 01 00 05  dNtcType........
02b0   62 64 47 62 6e 00 01 00 ff 00 01 00 03 63 68 6b  bdGbn........chk
02c0   00 01 00 ff 00 01 00 08 62 64 4e 6f 74 69 49 64  ........bdNotiId
02d0   00 01 00 ff 00 01 00 08 62 64 42 69 64 45 64 74  ........bdBidEdt
02e0   00 01 00 ff 00 01 00 08 62 64 4f 70 65 6e 44 74  ........bdOpenDt
02f0   00 01 00 ff 00 01 00 0b 65 76 61 6c 43 6f 6d 6d  ........evalComm
0300   43 6e 74 00 01 00 ff 00 01 00 07 65 6c 65 53 74  Cnt........eleSt
0310   61 74 00 01 00 ff 00 01 00 0b 62 64 50 6c 61 6e  at........bdPlan
0320   50 72 69 63 65 00 01 00 ff 00 01 00 08 62 64 4e  Price........bdN
0330   6f 74 69 44 6e 00 01 00 ff 00 01 00 07 72 65 61  otiDn........rea
0340   6c 43 6e 74 00 01 00 ff 00 01 00 09 62 64 4e 74  lCnt........bdNt
0350   63 42 61 73 65 00 01 00 ff 00 01 00 0d 62 64 4f  cBase........bdO
0360   70 65 6e 50 72 6f 63 45 6d 70 00 01 00 ff 00 01  penProcEmp......
0370   00 07 73 70 72 6f 63 59 6e 00 01 00 ff 00 01 00  ..sprocYn.......
0380   0d 62 64 50 72 69 63 65 4f 70 65 6e 59 6e 00 01  .bdPriceOpenYn..
0390   00 ff 00 01 00 0f 62 64 4e 74 63 50 72 6f 63 54  ......bdNtcProcT
03a0   79 70 65 4e 6d 00 01 00 ff 00 01 00 05 73 64 74  ypeNm........sdt
03b0   59 6e 00 01 00 ff 00 01 00 0a 64 65 6d 61 6e 64  Yn........demand
03c0   44 65 70 74 00 01 00 ff 00 01 00 06 62 64 42 69  Dept........bdBi
03d0   67 6f 00 01 00 ff 00 01 00 08 62 64 4e 74 63 4e  go........bdNtcN
03e0   75 6d 00 01 00 ff 00 01 00 0b 62 64 4e 74 63 42  um........bdNtcB
03f0   61 73 65 4e 6d 00 01 00 ff 00 01 00 0c 62 64 4f  aseNm........bdO
0400   70 65 6e 50 72 6f 63 44 74 00 01 00 ff 00 01 00  penProcDt.......
0410   06 65 6c 65 53 65 71 00 01 00 ff 00 01 00 0c 62  .eleSeq........b
0420   64 4e 74 63 50 72 6f 63 42 69 64 00 01 00 ff 00  dNtcProcBid.....
0430   01 00 06 72 65 63 45 64 74 00 01 00 ff 00 01 00  ...recEdt.......
0440   07 62 64 4e 74 63 44 74 00 01 00 ff 00 01 00 09  .bdNtcDt........
0450   62 64 52 65 61 6c 4e 75 6d 00 01 00 ff 00 01 00  bdRealNum.......
0460   0a 6d 69 6e 64 45 76 61 6c 4e 6d 00 01 00 ff 00  .mindEvalNm.....
0470   01 01 78 00 01 00 36 00 00 00 08 00 0c 32 30 31  ..x...6......201
0480   37 31 30 31 38 31 38 30 30 00 08 00 0c 32 30 31  710181800....201
0490   37 31 30 31 31 31 38 30 30 00 00 00 08 00 01 59  710111800......Y
04a0   00 00 00 00 00 00 00 00 00 08 00 01 59 00 08 00  ............Y...
04b0   02 30 33 00 08 00 06 eb ac bc ed 92 88 00 05 3f  .03............?
04c0   f0 00 00 00 00 00 00 00 00 00 08 00 35 eb b6 80  ............5...
04d0   eb 8c 80 ea b1 b4 eb ac bc 20 ec a0 84 ea b8 b0  ......... ......
04e0   ec 8b a4 20 eb b0 8f 20 ec b0 bd ea b3 a0 20 ea  ... ... ...... .
04f0   b0 9c ec 84 a0 eb ac bc ed 92 88 20 ea b5 ac eb  ........... ....
0500   a7 a4 00 08 00 0b 32 30 31 37 30 30 30 30 39 36  ......2017000096
0510   33 00 08 00 02 37 30 00 00 00 08 00 02 30 33 00  3....70......03.
0520   08 00 0c ec a0 9c ed 95 9c ea b2 bd ec 9f 81 00  ................
0530   08 00 02 30 31 00 08 00 0c ec a0 84 ec 9e 90 ec  ...01...........
0540   9e 85 ec b0 b0 00 00 00 00 00 00 00 00 00 00 00  ................
0550   08 00 0c 32 30 31 37 31 30 31 39 31 34 30 30 00  ...201710191400.
0560   08 00 0c 32 30 31 37 31 30 31 38 30 39 30 30 00  ...201710180900.
0570   00 00 08 00 0c 32 30 31 37 2d 30 35 35 38 2d 30  .....2017-0558-0
0580   30 00 00 00 08 00 02 31 30 00 08 00 0c ec 9e 85  0......10.......
0590   ec b0 b0 ea b3 b5 ea b3 a0 00 08 00 01 30 00 00  .............0..
05a0   00 08 00 08 34 31 30 30 30 30 38 34 00 08 00 0f  ....41000084....
05b0   ec a0 84 eb a0 a5 ec 9a b4 ec 98 81 ed 8c 80 00  ................
05c0   00 00 00 00 00 00 00 00 00 00 00 00 08 00 0a 31  ...............1
05d0   30 30 30 30 30 36 32 33 33 00 00 00 00 00 00 00  000006233.......
05e0   00 00 00 00 00 00 00 00 00 00 00 01 7b 00 01 00  ............{...
05f0   36 00 00 00 08 00 0c 32 30 31 37 31 30 31 38 31  6......201710181
0600   38 30 30 00 08 00 0c 32 30 31 37 31 30 31 31 30  800....201710110
0610   39 30 30 00 00 00 08 00 01 59 00 00 00 00 00 00  900......Y......
0620   00 00 00 08 00 01 59 00 08 00 02 30 32 00 08 00  ......Y....02...
0630   06 ec 9a a9 ec 97 ad 00 05 3f f0 00 00 00 00 00  .........?......
0640   00 00 00 00 08 00 2f ec 9d b8 ec b2 9c ea b3 b5  ....../.........
0650   ed 95 ad 20 eb aa b0 eb 93 9c eb b3 80 ec 95 95  ... ............
0660   ea b8 b0 20 ec a0 95 eb b0 80 ec a0 90 ea b2 80  ... ............
0670   ec 9a a9 ec 97 ad 00 08 00 0b 32 30 31 37 30 30  ..........201700
0680   30 30 39 36 32 00 08 00 02 37 30 00 00 00 08 00  00962....70.....
0690   02 30 31 00 08 00 0c ec 9d bc eb b0 98 ea b2 bd  .01.............
06a0   ec 9f 81 00 08 00 02 30 31 00 08 00 0c ec a0 84  .......01.......
06b0   ec 9e 90 ec 9e 85 ec b0 b0 00 00 00 00 00 00 00  ................
06c0   00 00 00 00 08 00 0c 32 30 31 37 31 30 31 39 31  .......201710191
06d0   36 30 30 00 08 00 0c 32 30 31 37 31 30 31 38 30  600....201710180
06e0   39 30 30 00 00 00 08 00 0c 32 30 31 37 2d 30 35  900......2017-05
06f0   35 37 2d 30 30 00 00 00 08 00 02 32 30 00 08 00  57-00......20...
0700   12 ec 9e 85 ec b0 b0 ec b0 b8 ea b0 80 eb 93 b1  ................
0710   eb a1 9d 00 08 00 01 30 00 00 00 08 00 08 34 31  .......0......41
0720   30 30 30 30 38 34 00 08 00 0f ec a0 84 eb a0 a5  000084..........
0730   ec 9a b4 ec 98 81 ed 8c 80 00 00 00 00 00 00 00  ................
0740   00 00 00 00 00 00 08 00 0a 31 30 30 30 30 30 36  .........1000006
0750   32 32 35 00 00 00 00 00 00 00 08 00 01 59 00 00  225..........Y..
0760   00 00 00 00 00 00 00 00 01 7d 00 01 00 36 00 00  .........}...6..
0770   00 08 00 0c 32 30 31 37 31 30 31 36 31 38 30 30  ....201710161800
0780   00 08 00 0c 32 30 31 37 31 30 31 31 30 39 30 30  ....201710110900
0790   00 00 00 08 00 01 59 00 00 00 00 00 00 00 00 00  ......Y.........
07a0   08 00 01 59 00 08 00 02 30 33 00 08 00 06 eb ac  ...Y....03......
07b0   bc ed 92 88 00 05 3f f0 00 00 00 00 00 00 00 00  ......?.........
07c0   00 08 00 2e 32 30 31 37 eb 85 84 20 ea b8 89 ec  ....2017... ....
07d0   9c a0 ec 8b 9c ec 84 a4 20 ec 9c a0 ec a7 80 ea  ........ .......
07e0   b4 80 eb a6 ac 20 ec 9e 90 ec 9e ac ea b5 ac eb  ..... ..........
07f0   a7 a4 00 08 00 0b 32 30 31 37 30 30 30 30 39 36  ......2017000096
0800   31 00 08 00 02 35 30 00 00 00 08 00 02 30 34 00  1....50......04.
0810   08 00 0c ec 88 98 ec 9d 98 ea b3 84 ec 95 bd 00  ................
0820   08 00 02 30 31 00 08 00 0c ec a0 84 ec 9e 90 ec  ...01...........
0830   9e 85 ec b0 b0 00 00 00 00 00 00 00 00 00 00 00  ................
0840   08 00 0c 32 30 31 37 31 30 31 37 31 34 30 30 00  ...201710171400.
0850   08 00 0c 32 30 31 37 31 30 31 36 30 39 30 30 00  ...201710160900.
0860   00 00 08 00 0c 32 30 31 37 2d 30 35 35 36 2d 30  .....2017-0556-0
0870   30 00 00 00 08 00 02 32 30 00 08 00 12 ec 9e 85  0......20.......
0880   ec b0 b0 ec b0 b8 ea b0 80 eb 93 b1 eb a1 9d 00  ................
0890   08 00 01 30 00 00 00 08 00 08 35 31 30 30 30 37  ...0......510007
08a0   36 38 00 08 00 12 ed 94 8c eb 9e 9c ed 8a b8 ec  68..............
08b0   8b 9c ec 84 a4 ed 8c 80 00 00 00 00 00 00 00 00  ................
08c0   00 00 00 00 00 08 00 0a 31 30 30 30 30 30 36 32  ........10000062
08d0   34 39 00 00 00 00 00 00 00 08 00 01 59 00 00 00  49..........Y...
08e0   00 00 00 00 00 00 00 01 85 00 01 00 36 00 00 00  ............6...
08f0   08 00 0c 32 30 31 37 31 30 31 37 31 38 30 30 00  ...201710171800.
0900   08 00 0c 32 30 31 37 31 30 31 30 31 34 30 30 00  ...201710101400.
0910   00 00 08 00 01 59 00 00 00 00 00 00 00 00 00 08  .....Y..........
0920   00 01 59 00 08 00 02 30 33 00 08 00 06 eb ac bc  ..Y....03.......
0930   ed 92 88 00 05 3f f0 00 00 00 00 00 00 00 00 00  .....?..........
0940   08 00 39 ed 95 ad ea b3 b5 eb 93 b1 ed 99 94 20  ..9............ 
0950   eb 8b a8 ec 9c 84 eb b0 b0 ec a0 84 eb b0 98 20  ............... 
0960   ea b0 90 ec 8b 9c ec 8b 9c ec 8a a4 ed 85 9c 20  ............... 
0970   ea b5 ac ec b6 95 ec 82 ac ec 97 85 00 08 00 0b  ................
0980   32 30 31 37 30 30 30 30 39 36 30 00 08 00 02 37  20170000960....7
0990   30 00 00 00 08 00 02 30 33 00 08 00 0c ec a0 9c  0......03.......
09a0   ed 95 9c ea b2 bd ec 9f 81 00 08 00 02 30 31 00  .............01.
09b0   08 00 0c ec a0 84 ec 9e 90 ec 9e 85 ec b0 b0 00  ................
09c0   00 00 00 00 00 00 00 00 00 00 08 00 0c 32 30 31  .............201
09d0   37 31 30 31 38 31 34 30 30 00 08 00 0c 32 30 31  710181400....201
09e0   37 31 30 31 37 30 39 30 30 00 00 00 08 00 0c 32  710170900......2
09f0   30 31 37 2d 30 35 35 35 2d 30 30 00 00 00 08 00  017-0555-00.....
0a00   02 32 30 00 08 00 12 ec 9e 85 ec b0 b0 ec b0 b8  .20.............
0a10   ea b0 80 eb 93 b1 eb a1 9d 00 08 00 01 30 00 00  .............0..
0a20   00 08 00 08 34 31 30 30 30 30 38 31 00 08 00 0f  ....41000081....
0a30   ed 95 ad ea b3 b5 eb 93 b1 ed 99 94 ed 8c 80 00  ................
0a40   00 00 00 00 00 00 00 00 00 00 00 00 08 00 0a 31  ...............1
0a50   30 30 30 30 30 36 32 32 33 00 00 00 00 00 00 00  000006223.......
0a60   08 00 01 59 00 00 00 00 00 00 00 00 00 00 01 7b  ...Y...........{
0a70   00 01 00 36 00 00 00 08 00 0c 32 30 31 37 31 30  ...6......201710
0a80   32 35 31 36 30 30 00 08 00 0c 32 30 31 37 31 30  251600....201710
0a90   31 30 30 39 30 30 00 00 00 08 00 01 59 00 00 00  100900......Y...
0aa0   00 00 00 00 00 00 08 00 01 59 00 08 00 02 30 32  .........Y....02
0ab0   00 08 00 06 ec 9a a9 ec 97 ad 00 05 3f f0 00 00  ............?...
0ac0   00 00 00 00 00 00 00 08 00 2c ec 9d b8 ec b2 9c  .........,......
0ad0   ea b3 b5 ed 95 ad 20 ec 8b 9c ec 84 a4 ea b0 9c  ...... .........
0ae0   ec 84 a0 20 ec 84 a4 ea b3 84 ec 9a a9 ec 97 ad  ... ............
0af0   28 50 4b 47 32 29 00 08 00 0b 32 30 31 37 30 30  (PKG2)....201700
0b00   30 30 39 34 31 00 08 00 02 38 30 00 00 00 08 00  00941....80.....
0b10   02 30 33 00 08 00 0c ec a0 9c ed 95 9c ea b2 bd  .03.............
0b20   ec 9f 81 00 08 00 02 30 31 00 08 00 0c ec a0 84  .......01.......
0b30   ec 9e 90 ec 9e 85 ec b0 b0 00 00 00 00 00 00 00  ................
0b40   00 00 00 00 08 00 0c 32 30 31 37 31 30 32 35 31  .......201710251
0b50   36 30 30 00 08 00 0c 32 30 31 37 31 30 32 35 31  600....201710251
0b60   36 30 30 00 00 00 08 00 0c 32 30 31 37 2d 30 35  600......2017-05
0b70   35 34 2d 30 30 00 00 00 08 00 02 32 30 00 08 00  54-00......20...

我在stackoverflow中剪切了一个pakcet cuz帖子大小。

这是Code

require 'vendor/autoload.php';
    error_reporting(E_ALL);
    ini_set('max_execution_time', 0);
    ini_set('memory_limit', -1);
    use GuzzleHttp\Client;
    use GuzzleHttp\Psr7;
    use GuzzleHttp\Psr7\Request;
    use GuzzleHttp\Post\PostFile;

    $cookie = "EBID_SESSION=yONu7j9HlagcY8ZkFhjxR7sQFFkq4TcRyVrHFl1zkLEadKEQ96Q1Waomd79QhK3C.aebdapp1_servlet_EBID2; GV_JSESSIONID=; HttpOnly=; JSESSIONID=yONu7j9HlagcY8ZkFhjxR7sQFFkq4TcRyVrHFl1zkLEadKEQ96Q1Waomd79QhK3C.aebdapp1_servl";

    $xml = new SimpleXMLElement('<xml/>');
    $root = $xml->addChild('root');
    $params = $root->addChild('params');


    $param = $params->addChild('param', "");
    $param->addAttribute("id", "bdNtcBase");
    $param->addAttribute("type", "STRING");

    $param = $params->addChild('param', "");
    $param->addAttribute("id", "bdNtcNm");
    $param->addAttribute("type", "STRING");

    $param = $params->addChild('param', "");
    $param->addAttribute("id", "bdStat");
    $param->addAttribute("type", "STRING");

    $param = $params->addChild('param', "EleBidNotice");
    $param->addAttribute("id", "beanName");
    $param->addAttribute("type", "STRING");

    $param = $params->addChild('param', "yONu7j9HlagcY8ZkFhjxR7sQFFkq4TcRyVrHFl1zkLEadKEQ96Q1Waomd79QhK3C.aebdapp1_servlet_EBID2");
    $param->addAttribute("id", "EBID_SESSION");
    $param->addAttribute("type", "STRING");

    $param = $params->addChild('param', "");
    $param->addAttribute("id", "GV_JSESSIONID");
    $param->addAttribute("type", "STRING");

    $param = $params->addChild('param', "");
    $param->addAttribute("id", "HttpOnly");
    $param->addAttribute("type", "STRING");

    $param = $params->addChild('param', "com.iiac.auri.ebid.eb.impl.EleBidNoticeSVO");
    $param->addAttribute("id", "inputVOName");
    $param->addAttribute("type", "STRING");

    $param = $params->addChild('param', "yONu7j9HlagcY8ZkFhjxR7sQFFkq4TcRyVrHFl1zkLEadKEQ96Q1Waomd79QhK3C.aebdapp1_servlet_EBID2");
    $param->addAttribute("id", "JSESSIONID");
    $param->addAttribute("type", "STRING");

    $param = $params->addChild('param', "selectNoticeVenList");
    $param->addAttribute("id", "methodName");
    $param->addAttribute("type", "STRING");

    $param = $params->addChild('param', "/");
    $param->addAttribute("id", "Path");
    $param->addAttribute("type", "STRING");

    $param = $params->addChild('param', "00147004015f09314a42575bac117321");
    $param->addAttribute("id", "PHAROSVISITOR");
    $param->addAttribute("type", "STRING");

    echo ($xml->asXML());


    $client = new Client();

    $request=$client->createRequest('POST', 'http://ebid.airport.kr/EleBidNotice.do',[
        'cookies'=>true,
        'headers'=>[
            'Host' => 'ebid.airport.kr',
            'Accept' => '*/*',
            'Cache-Control' => 'no-cache',
            'Content-Type' => 'text/xml;charset=utf-8',
            'Content-Length' => '982',
            'Connection' => 'close',
            'Accept-Encoding' => 'gzip, deflate',
            'User-Agent' => 'MiPlatform 3.2;win32;1920x1200',
            'Accept-Charset' => 'utf-8',
            'Accept-Language' => 'ko-KR',
            'Cookie'=>$cookie,
        ],
        'body' => array(
            'file_filed' => $xml->asXML()
        )
    ]);

    $response = $client->send($request);
    print_r($response);
    echo $response->getStatusCode(),PHP_EOL;      // >>> 200
    echo $response->getReasonPhrase(),PHP_EOL;    // >>> OK


    $body = $response->getBody(true);


    var_dump($body);

    echo $body,PHP_EOL;
    echo '<pre>' . $response->getBody()->getContents() . '</pre>';

0 个答案:

没有答案