libcurl http get out of memory error.
libcurl http get out of memory error.
https://github.com/loboris/ESP32_curl_example/issues/6
Kindly check this. let me know issue. I am doing http get using libCurl.
Kindly check this. let me know issue. I am doing http get using libCurl.
Re: libcurl http get out of memory error.
"I have increase of task stack size to 50000 to make it work .still write to sd card. empty file."snahmad75 wrote:https://github.com/loboris/ESP32_curl_example/issues/6
Kindly check this. let me know issue. I am doing http get using libCurl.
Increasing the stack size should only make it worse.
Re: libcurl http get out of memory error.
Full logs. Out of memory. My task stack size is = 25000.
What is the solution.
#### HTTP GET BIG FILE
V (10356) FreeRTOS: Semaphore taking: name: ServerStarted (0x3ffdf118), owner:
<N/A> for start
V (10363) vfs_fat: vfs_fat_open: path="/alarm.json", flags=601, mode=1b6
V (10368) FreeRTOS: Semaphore taken: name: ServerStarted (0x3ffdf118), owner:
start
V (10375) sdmmc_cmd: sending cmd slot=1 op=17 arg=12000 flags=1c50 data=0x3ffb
e14c blklen=512 datalen=512 timeout=1000
D (10382) HttpServer: << start
D (10384) Task: >> runTask: taskName=HttpServerTask
V (10393) sdspi_host: sdspi_host_start_command: slot=1, CMD17, arg=0x00012000
flags=0x5, data=0x3ffbe14c, data_size=512 crc=0x77
D (10396) Task: << runTask: taskName=Task
D (10401) Socket: >> setSSL: No
V (10419) sdspi_transaction: r1 = 0x00 hw_cmd.r[0]=0x49002042
D (10421) Socket: >> listen: port: 80, isDatagram: 0
V (10426) sdmmc_cmd: cmd response 00000000 00000000 00000000 00000000 err=0x0
state=0
D (10431) Socket: >> createSocket: isDatagram: 0
curl_easy_perform failed: Out of memory
D (10444) Socket: << createSocket: sockFd: 8196
V (10448) sdmmc_cmd: sending cmd slot=1 op=24 arg=12000 flags=1c10 data=0x3ffb
e14c blklen=512 datalen=512 timeout=5000
D (10453) Socket: >> setReuseAddress: 1
V (10462) sdspi_host: sdspi_host_start_command: slot=1, CMD24, arg=0x00012000
flags=0x7, data=0x3ffbe14c, data_size=512 crc=0x6a
D (10469) Socket: << setReuseAddress
D (10481) Socket: >> bind: port=80, address=0x0
V (10485) sdspi_transaction: r1 = 0x00 hw_cmd.r[0]=0xffffffff
D (10487) Socket: << bind
V (10493) sdmmc_cmd: cmd response 00000000 00000000 00000000 00000000 err=0x0
state=0
D (10498) Socket: << listen
ERROR: -7 [Out of memory]
D (10506) HttpServerTask: Listening on port 80
D (10512) HttpServerTask: Waiting for new peer client
D (10517) Socket: >> accept: Accepting on 0.0.0.0 [80]; sockFd: 8196, using SS
What is the solution.
#### HTTP GET BIG FILE
V (10356) FreeRTOS: Semaphore taking: name: ServerStarted (0x3ffdf118), owner:
<N/A> for start
V (10363) vfs_fat: vfs_fat_open: path="/alarm.json", flags=601, mode=1b6
V (10368) FreeRTOS: Semaphore taken: name: ServerStarted (0x3ffdf118), owner:
start
V (10375) sdmmc_cmd: sending cmd slot=1 op=17 arg=12000 flags=1c50 data=0x3ffb
e14c blklen=512 datalen=512 timeout=1000
D (10382) HttpServer: << start
D (10384) Task: >> runTask: taskName=HttpServerTask
V (10393) sdspi_host: sdspi_host_start_command: slot=1, CMD17, arg=0x00012000
flags=0x5, data=0x3ffbe14c, data_size=512 crc=0x77
D (10396) Task: << runTask: taskName=Task
D (10401) Socket: >> setSSL: No
V (10419) sdspi_transaction: r1 = 0x00 hw_cmd.r[0]=0x49002042
D (10421) Socket: >> listen: port: 80, isDatagram: 0
V (10426) sdmmc_cmd: cmd response 00000000 00000000 00000000 00000000 err=0x0
state=0
D (10431) Socket: >> createSocket: isDatagram: 0
curl_easy_perform failed: Out of memory
D (10444) Socket: << createSocket: sockFd: 8196
V (10448) sdmmc_cmd: sending cmd slot=1 op=24 arg=12000 flags=1c10 data=0x3ffb
e14c blklen=512 datalen=512 timeout=5000
D (10453) Socket: >> setReuseAddress: 1
V (10462) sdspi_host: sdspi_host_start_command: slot=1, CMD24, arg=0x00012000
flags=0x7, data=0x3ffbe14c, data_size=512 crc=0x6a
D (10469) Socket: << setReuseAddress
D (10481) Socket: >> bind: port=80, address=0x0
V (10485) sdspi_transaction: r1 = 0x00 hw_cmd.r[0]=0xffffffff
D (10487) Socket: << bind
V (10493) sdmmc_cmd: cmd response 00000000 00000000 00000000 00000000 err=0x0
state=0
D (10498) Socket: << listen
ERROR: -7 [Out of memory]
D (10506) HttpServerTask: Listening on port 80
D (10512) HttpServerTask: Waiting for new peer client
D (10517) Socket: >> accept: Accepting on 0.0.0.0 [80]; sockFd: 8196, using SS
Re: libcurl http get out of memory error.
I can avoid using libCurl and use socket http get file chunk by chunk and write SD card as file.
Later on I need HTTPS. I guess kolban Https C++ class will do the job.
Later on I need HTTPS. I guess kolban Https C++ class will do the job.
Re: libcurl http get out of memory error.
A stack size of 25K is using up a lot of memory. Granted if you only have one task that might be OK. Do you have a reason for such a large stack? Maybe try 6K, or tell us what you are putting on the stack that makes the need so high.
Put this in your app so we can see what you are dealing with...
John A
Put this in your app so we can see what you are dealing with...
Code: Select all
UBaseType_t uxHighWaterMark = uxTaskGetStackHighWaterMark( NULL );
printf("Stack free: %d\r\n", uxHighWaterMark);
printf("Internal Heap free: %d\r\n", heap_caps_get_free_size(MALLOC_CAP_INTERNAL));
printf("Heap free: %d:%d\r\n", heap_caps_get_free_size(MALLOC_CAP_8BIT),
heap_caps_get_free_size(MALLOC_CAP_32BIT));
Re: libcurl http get out of memory error.
Yes A stack size of 25K is using up a lot of memory. I already have few others task needs max of 12000 stack size.
Already consume too many ram. RAM size on esp32 is 512kb. I get of main start 256 kb checked by heap stats as first line in main.
I will need heap and stack for later for secure http. not used yet.
I was just trying to make libCurl works without giving me out memory error. I can using simple http C or C++ function to get http files one by files and write to sd card as files by avoiding libCurl.
I managed to use OTA example to do http get chunk by chunck for my binary image. I guess i can simple way for each web files and write to sd card.
I will try stack and heap stats in my program tomorrow and let you know results.
Thanks for your input.
Already consume too many ram. RAM size on esp32 is 512kb. I get of main start 256 kb checked by heap stats as first line in main.
I will need heap and stack for later for secure http. not used yet.
I was just trying to make libCurl works without giving me out memory error. I can using simple http C or C++ function to get http files one by files and write to sd card as files by avoiding libCurl.
I managed to use OTA example to do http get chunk by chunck for my binary image. I guess i can simple way for each web files and write to sd card.
I will try stack and heap stats in my program tomorrow and let you know results.
Thanks for your input.
curl_easy_perform failed: Out of memory
Hi,
check logs below. any idea. Let me try libCurl example as well.
https://github.com/loboris/ESP32_curl_example
1- On my application starts:
on start ram usage
Stack free: 2696
Internal Heap free: 342492
Heap free: 269572:342492
on start free heap=269572
2- On my http get Task run
Stack free: 23100
Internal Heap free: 142948
V (10378) FreeRTOS: Semaphore taken: name: ServerStarted (0x3ffdff50), owner:
start
Heap free: 70028:142948
#### HTTP GET BIG FILE
D (10390) HttpServer: << start
D (10392) Task: >> runTask: taskName=HttpServerTask
D (10398) Task: << runTask: taskName=Task
V (10398) vfs_fat: vfs_fat_open: path="/alarm.json", flags=601, mode=1b6
D (10403) Socket: >> setSSL: No
V (10413) sdmmc_cmd: sending cmd slot=1 op=17 arg=12000 flags=1c50 data=0x3ffb
e14c blklen=512 datalen=512 timeout=1000
D (10416) Socket: >> listen: port: 80, isDatagram: 0
V (10427) sdspi_host: sdspi_host_start_command: slot=1, CMD17, arg=0x00012000
flags=0x5, data=0x3ffbe14c, data_size=512 crc=0x77
D (10432) Socket: >> createSocket: isDatagram: 0
D (10447) Socket: << createSocket: sockFd: 8196
V (10449) sdspi_transaction: r1 = 0x00 hw_cmd.r[0]=0x49002042
D (10453) Socket: >> setReuseAddress: 1
V (10458) sdmmc_cmd: cmd response 00000000 00000000 00000000 00000000 err=0x0
state=0
D (10465) Socket: << setReuseAddress
D (10472) Socket: >> bind: port=80, address=0x0
curl_easy_perform failed: Out of memory
D (10480) Socket: << bind
V (10483) sdmmc_cmd: sending cmd slot=1 op=24 arg=12000 flags=1c10 data=0x3ffb
e14c blklen=512 datalen=512 timeout=5000
D (10488) Socket: << listen
D (10496) HttpServerTask: Listening on port 80
V (10497) sdspi_host: sdspi_host_start_command: slot=1, CMD24, arg=0x00012000
flags=0x7, data=0x3ffbe14c, data_size=512 crc=0x6a
D (10504) HttpServerTask: Waiting for new peer client
D (10521) Socket: >> accept: Accepting on 0.0.0.0 [80]; sockFd: 8196, using SS
L: 0
V (10522) sdspi_transaction: r1 = 0x00 hw_cmd.r[0]=0xffffffff
V (10531) sdmmc_cmd: cmd response 00000000 00000000 00000000 00000000 err=0x0
state=0
ERROR: -7 [Out of memory]
check logs below. any idea. Let me try libCurl example as well.
https://github.com/loboris/ESP32_curl_example
1- On my application starts:
on start ram usage
Stack free: 2696
Internal Heap free: 342492
Heap free: 269572:342492
on start free heap=269572
2- On my http get Task run
Stack free: 23100
Internal Heap free: 142948
V (10378) FreeRTOS: Semaphore taken: name: ServerStarted (0x3ffdff50), owner:
start
Heap free: 70028:142948
#### HTTP GET BIG FILE
D (10390) HttpServer: << start
D (10392) Task: >> runTask: taskName=HttpServerTask
D (10398) Task: << runTask: taskName=Task
V (10398) vfs_fat: vfs_fat_open: path="/alarm.json", flags=601, mode=1b6
D (10403) Socket: >> setSSL: No
V (10413) sdmmc_cmd: sending cmd slot=1 op=17 arg=12000 flags=1c50 data=0x3ffb
e14c blklen=512 datalen=512 timeout=1000
D (10416) Socket: >> listen: port: 80, isDatagram: 0
V (10427) sdspi_host: sdspi_host_start_command: slot=1, CMD17, arg=0x00012000
flags=0x5, data=0x3ffbe14c, data_size=512 crc=0x77
D (10432) Socket: >> createSocket: isDatagram: 0
D (10447) Socket: << createSocket: sockFd: 8196
V (10449) sdspi_transaction: r1 = 0x00 hw_cmd.r[0]=0x49002042
D (10453) Socket: >> setReuseAddress: 1
V (10458) sdmmc_cmd: cmd response 00000000 00000000 00000000 00000000 err=0x0
state=0
D (10465) Socket: << setReuseAddress
D (10472) Socket: >> bind: port=80, address=0x0
curl_easy_perform failed: Out of memory
D (10480) Socket: << bind
V (10483) sdmmc_cmd: sending cmd slot=1 op=24 arg=12000 flags=1c10 data=0x3ffb
e14c blklen=512 datalen=512 timeout=5000
D (10488) Socket: << listen
D (10496) HttpServerTask: Listening on port 80
V (10497) sdspi_host: sdspi_host_start_command: slot=1, CMD24, arg=0x00012000
flags=0x7, data=0x3ffbe14c, data_size=512 crc=0x6a
D (10504) HttpServerTask: Waiting for new peer client
D (10521) Socket: >> accept: Accepting on 0.0.0.0 [80]; sockFd: 8196, using SS
L: 0
V (10522) sdspi_transaction: r1 = 0x00 hw_cmd.r[0]=0xffffffff
V (10531) sdmmc_cmd: cmd response 00000000 00000000 00000000 00000000 err=0x0
state=0
ERROR: -7 [Out of memory]
Re: libcurl http get out of memory error.
So many issues using libcurl. even using this example not working for me. any idea>
https://github.com/loboris/ESP32_curl_example
#### HTTP GET FILE
Get file (~225 KB) from http server and save it to file system
V (20051) vfs_fat: vfs_fat_open: path="/alarm.json", flags=601, mode=1b6
D (20054) vfs_fat: vfs_fat_open: fresult=6
ERROR: -6 []
https://github.com/loboris/ESP32_curl_example
#### HTTP GET FILE
Get file (~225 KB) from http server and save it to file system
V (20051) vfs_fat: vfs_fat_open: path="/alarm.json", flags=601, mode=1b6
D (20054) vfs_fat: vfs_fat_open: fresult=6
ERROR: -6 []
Re: libcurl http get out of memory error.
In my experience you are using too much stack and that is why I think you are running out of memory. How do you know you need that much stack for your tasks? I'm not using anywhere close to that for any of my tasks. I would have been out of memory a long time ago if I did.Yes A stack size of 25K is using up a lot of memory. I already have few others task needs max of 12000 stack size.
Your heap printout doesn't appear to be that close to running out. But having multiple tasks with 12K and this one at 25K does seem suspect. Plus, look at the min stack on your task is still at 23K when calling the routine you run out. Try making it 6K instead of 25K.
John A
Re: libcurl http get out of memory error.
To test I've cloned the ESP32_curl_example repository into new directory.
Run:
I've only changed WiFi and mail data in menuconfig.
Main task stack size is 3584 B (default).
There was no problem and all examples passed without any issue:
Run:
Code: Select all
make menuconfig
make -j8 all
make flush
make monitor
Main task stack size is 3584 B (default).
There was no problem and all examples passed without any issue:
Code: Select all
I (4764) [cURL Example]: SYSTEM_EVENT_STA_CONNECTED
I (7096) event: sta ip: 192.168.0.21, mask: 255.255.255.0, gw: 192.168.0.1
I (7097) [cURL Example]: SYSTEM_EVENT_STA_GOT_IP
I (7099) [cURL Example]: got ip:192.168.0.21 ... ready to go!
Removing files on file system...
=========
cURL INFO
=========
Curl version info
version: 7.58.0-DEV - 473600
Host: ESP32
- IP V6 supported
- SSL supported
- LIBZ supported
- NTLM NOT supported
- DEBUG NOT supported
- UNIX sockets NOT supported
Protocols:
- dict
- file
- ftp
- ftps
- gopher
- http
- https
- imap
- imaps
- pop3
- pop3s
- rtsp
- scp
- sftp
- smtp
- smtps
- telnet
- tftp
Starting in 1 seconds...
--------------------------------------------------------
I (19146) [cURL Example]: === PASS 1; restart_cnt=0 ===
--------------------------------------------------------
#### HTTP GET
Send GET request with parameters
* timeout on name lookup is not supported
* Trying 82.196.4.208...
* TCP_NODELAY set
* Connected to loboris.eu (82.196.4.208) port 80 (#0)
> GET /ESP32/test.php?par1=765&par2=test HTTP/1.1
Host: loboris.eu
Accept: */*
Accept-Encoding: deflate, gzip
< HTTP/1.1 200 OK
< Date: Tue, 15 May 2018 12:20:27 GMT
< Server: Apache/2.4.7 (Ubuntu)
< X-Powered-By: PHP/5.5.9-1ubuntu4.23
< Vary: Accept-Encoding
< Content-Encoding: gzip
< Content-Length: 212
< Content-Type: text/html
<
* Closing connection 0
____________ Response BODY: ____________
============
Method: GET
============
--------------------------
Number of uploaded files: 0
Number of GET params: 2
Number of POST params: 0
--------------------------
===========
Debug info:
===========
-----------
POST DATA:
-----------
Array
(
)
-----------
GET DATA:
-----------
Array
(
[par1] => 765
[par2] => test
)
-----------
FILE DATA:
-----------
Array
(
)
-----------
=====================================
LoBo test server, 2018/05/15 14:20:27
=====================================
^^^^^^^^^^^^ Response BODY: ^^^^^^^^^^^^
#### HTTP GET FILE
Get file (~225 KB) from http server and save it to file system
* timeout on name lookup is not supported
* Trying 82.196.4.208...
* TCP_NODELAY set
* Connected to loboris.eu (82.196.4.208) port 80 (#0)
> GET /ESP32/tiger.bmp HTTP/1.1
Host: loboris.eu
Accept: */*
Accept-Encoding: deflate, gzip
< HTTP/1.1 200 OK
< Date: Tue, 15 May 2018 12:20:29 GMT
< Server: Apache/2.4.7 (Ubuntu)
< Last-Modified: Mon, 30 Jan 2017 19:12:04 GMT
< ETag: "38438-5475497410900"
< Accept-Ranges: bytes
< Content-Length: 230456
< Content-Type: image/x-ms-bmp
<
* Download: received 149106
* Closing connection 0
* Download: received 230456 B; time=8.4 s; speed=26.9 KB/sec
____________ Response BODY: ____________
Saved to file /spiflash/tiger.bmp, size=230456
^^^^^^^^^^^^ Response BODY: ^^^^^^^^^^^^
#### HTTP GET BIG FILE
Get big file (~2.4 MB), simulate saving to file system
* timeout on name lookup is not supported
* Trying 82.196.4.208...
* TCP_NODELAY set
* Connected to loboris.eu (82.196.4.208) port 80 (#0)
> GET /ESP32/bigimg.jpg HTTP/1.1
Host: loboris.eu
Accept: */*
Accept-Encoding: deflate, gzip
< HTTP/1.1 200 OK
< Date: Tue, 15 May 2018 12:20:39 GMT
< Server: Apache/2.4.7 (Ubuntu)
< Last-Modified: Sun, 29 May 2016 16:55:19 GMT
< ETag: "25090a-533fe013c6bc0"
< Accept-Ranges: bytes
< Content-Length: 2427146
< Content-Type: image/jpeg
<
* Download: received 769460
* Download: received 1556388
* Download: received 2339008
* Closing connection 0
* Download: received 2427146 B; time=15.6 s; speed=151.7 KB/sec
____________ Response BODY: ____________
SIMULATED save to file; size=2427146
^^^^^^^^^^^^ Response BODY: ^^^^^^^^^^^^
#### HTTPS (SSL) GET
Send GET request to secure (SSL) server
* timeout on name lookup is not supported
* Trying 198.128.229.135...
* TCP_NODELAY set
* Connected to www-eng-x.llnl.gov (198.128.229.135) port 443 (#0)
* Error reading ca cert file /certs/ca-certificates.crt - mbedTLS: (-0x3E00) PK - Read/write of file failed
* mbedTLS: Connecting to www-eng-x.llnl.gov:443
* mbedTLS: Set min SSL version to TLS 1.0
* mbedTLS: Handshake complete, cipher is TLS-ECDHE-RSA-WITH-AES-256-GCM-SHA384
* Dumping cert info:
* cert. version : 3
* serial number : 03:2C:94:4A:72:57:00:7E:A4:41:61:E2:AE:2F:3C:32:C8:DD
* issuer name : C=US, O=Let's Encrypt, CN=Let's Encrypt Authority X3
* subject name : CN=www-br.llnl.gov
* issued on : 2018-05-01 06:44:13
* expires on : 2018-07-30 06:44:13
* signed using : RSA with SHA-256
* RSA key size : 2048 bits
* basic constraints : CA=false
* subject alt name : www-br.llnl.gov, www-br.ucllnl.org, www-eng-x.llnl.gov
* key usage : Digital Signature, Key Encipherment
* ext key usage : TLS Web Server Authentication, TLS Web Client Authentication
* SSL connected
> GET /documents/a_document.txt HTTP/1.1
Host: www-eng-x.llnl.gov
Accept: */*
Accept-Encoding: deflate, gzip
< HTTP/1.1 200 OK
< Date: Tue, 15 May 2018 12:22:19 GMT
< Server: Apache
< Strict-Transport-Security: max-age=31536000; includeSubdomains; preload
< Last-Modified: Thu, 20 Apr 1995 07:00:00 GMT
< ETag: "6e-2d61af3ba7c00"
< Accept-Ranges: bytes
< Content-Length: 110
< Connection: close
< Content-Type: text/plain; charset=UTF-8
<
* Closing connection 0
____________ Response BODY: ____________
This is a test
The quick brown fox jumped over the lazy dogs.
1234567890!@#$%^&*()[]{}-=_+;:'",.<>/?`~\|
^^^^^^^^^^^^ Response BODY: ^^^^^^^^^^^^
#### HTTP POST
Send POST request with 3 parameters
* timeout on name lookup is not supported
* Trying 161.53.81.17...
* TCP_NODELAY set
* Connected to amp.dhz.hr (161.53.81.17) port 443 (#0)
* Error reading ca cert file /certs/ca-certificates.crt - mbedTLS: (-0x3E00) PK - Read/write of file failed
* mbedTLS: Connecting to amp.dhz.hr:443
* mbedTLS: Set min SSL version to TLS 1.0
* mbedTLS: Handshake complete, cipher is TLS-ECDHE-RSA-WITH-AES-256-GCM-SHA384
* Dumping cert info:
* cert. version : 3
* serial number : 8B:FB:43:39:DA:90:74:77
* issuer name : CN=lubuntu
* subject name : CN=lubuntu
* issued on : 2013-11-04 10:22:26
* expires on : 2023-11-02 10:22:26
* signed using : RSA with SHA1
* RSA key size : 2048 bits
* basic constraints : CA=false
* SSL connected
> POST /test/test.php HTTP/1.1
Host: amp.dhz.hr
Accept: */*
Accept-Encoding: deflate, gzip
Content-Length: 355
Content-Type: multipart/form-data; boundary=------------------------df0496cb4960d020
< HTTP/1.1 200 OK
< Date: Tue, 15 May 2018 12:22:21 GMT
< Server: Apache/2.4.7 (Ubuntu)
< X-Powered-By: PHP/5.5.9-1ubuntu4.20
< Vary: Accept-Encoding
< Content-Encoding: gzip
< Content-Length: 229
< Content-Type: text/html
<
* Closing connection 0
____________ Response BODY: ____________
============
Method: POST
============
--------------------------
Number of uploaded files: 0
Number of GET params: 0
Number of POST params: 3
--------------------------
===========
Debug info:
===========
-----------
POST DATA:
-----------
Array
(
[param1] => 1234
[param2] => esp32
[param3] => Test from ESP32
)
-----------
GET DATA:
-----------
Array
(
)
-----------
FILE DATA:
-----------
Array
(
)
-----------
=====================================
LoBo test server, 2018/05/15 14:22:21
=====================================
^^^^^^^^^^^^ Response BODY: ^^^^^^^^^^^^
#### FTP LIST TEST
List files on FTP server
* Rebuilt URL to: ftp://loboris.eu/
* timeout on name lookup is not supported
* Trying 82.196.4.208...
* TCP_NODELAY set
* Connected to loboris.eu (82.196.4.208) port 21 (#0)
< 220 LoBo FTP Server
> AUTH SSL
< 500 AUTH not understood
> AUTH TLS
< 500 AUTH not understood
> USER esp32
< 331 Password required for esp32
> PASS esp32user
< 230 Anonymous access granted, restrictions apply
> PWD
< 257 "/" is the current directory
* Entry path is '/'
> PASV
* Connect data stream passively
* ftp_perform ends with SECONDARY: 0
< 227 Entering Passive Mode (82,196,4,208,192,23).
* Trying 82.196.4.208...
* TCP_NODELAY set
* Connecting to 82.196.4.208 (82.196.4.208) port 49175
* Connected to loboris.eu (82.196.4.208) port 21 (#0)
> TYPE A
< 200 Type set to A
> LIST
< 150 Opening ASCII mode data connection for file list
* Maxdownload = -1
* Remembering we are in dir ""
< 226 Transfer complete
> QUIT
< 221 Goodbye.
* Closing connection 0
____________ Response BODY: ____________
-rw-r--r-- 1 esp32 esp32group 2427146 May 1 2017 big.jpg
-rw-r--r-- 1 esp32 esp32group 2427146 May 2 2017 bigimg.jpg
-rw-r--r-- 1 esp32 esp32group 97543 Sep 26 2017 bmp.bmp
-rw-r--r-- 1 esp32 esp32group 23278 May 10 2017 door.php
-rw-r--r-- 1 root root 609 May 5 2017 ftptest.txt
-rw-r--r-- 1 esp32 esp32group 97543 Sep 26 2017 moujib.jpg
-rw-r--r-- 1 esp32 esp32group 97543 May 15 12:29 put_test.jpg
-rw-r--r-- 1 esp32 esp32group 16368 May 15 11:25 put_test.txt
-rw-r--r-- 1 esp32 esp32group 97543 Sep 23 2017 put_test1.jpg
-rw-r--r-- 1 esp32 esp32group 97543 Sep 26 2017 put_test2 .jpg
-rw-r--r-- 1 esp32 esp32group 97543 Sep 25 2017 put_test2.jpg
-rw-r--r-- 1 esp32 esp32group 97543 Sep 26 2017 put_test3.jpg
-rw-r--r-- 1 esp32 esp32group 97543 Sep 26 2017 put_test6.jpg
drwxr-xr-x 1 esp32 esp32group 32 Jan 22 15:10 test
-rw-r--r-- 1 esp32 esp32group 583 May 1 2017 test.txt
-rw-r--r-- 1 esp32 esp32group 230456 Apr 30 2017 tiger.bmp
-rw-r--r-- 1 esp32 esp32group 97543 Jan 30 2017 tiger240.jpg
^^^^^^^^^^^^ Response BODY: ^^^^^^^^^^^^
#### FTP GET TEXT FILE
Get small text file from FTP server
* timeout on name lookup is not supported
* Trying 82.196.4.208...
* TCP_NODELAY set
* Connected to loboris.eu (82.196.4.208) port 21 (#0)
< 220 LoBo FTP Server
> AUTH SSL
< 500 AUTH not understood
> AUTH TLS
< 500 AUTH not understood
> USER esp32
< 331 Password required for esp32
> PASS esp32user
< 230 Anonymous access granted, restrictions apply
> PWD
< 257 "/" is the current directory
* Entry path is '/'
> PASV
* Connect data stream passively
* ftp_perform ends with SECONDARY: 0
< 227 Entering Passive Mode (82,196,4,208,192,37).
* Trying 82.196.4.208...
* TCP_NODELAY set
* Connecting to 82.196.4.208 (82.196.4.208) port 49189
* Connected to loboris.eu (82.196.4.208) port 21 (#0)
> TYPE I
< 200 Type set to I
> SIZE ftptest.txt
< 213 609
> RETR ftptest.txt
< 150 Opening BINARY mode data connection for ftptest.txt (609 bytes)
* Maxdownload = -1
* Getting file with size: 609
* Remembering we are in dir ""
< 226 Transfer complete
> QUIT
< 221 Goodbye.
* Closing connection 0
____________ Response BODY: ____________
=== Do you speak Latin ?
Lorem ipsum dolor sit amet, consectetur adipiscing elit.
Nam rhoncus odio id venenatis volutpat.
Vestibulum dapibus bibendum ullamcorper.
Maecenas finibus elit augue, vel condimentum odio maximus nec.
In hac habitasse platea dictumst.
Vestibulum vel dolor et turpis rutrum finibus ac at nulla.
Vivamus nec neque ac elit blandit pretium vitae maximus ipsum.
Quisque sodales magna vel erat auctor, sed pellentesque nisi rhoncus.
Donec vehicula maximus pretium.
Aliquam eu tincidunt lorem.
Ut placerat, sem eu pharetra mattis, ante lacus fringilla diam, a consequat quam eros eget erat.
^^^^^^^^^^^^ Response BODY: ^^^^^^^^^^^^
Received file saved to '/spiflash/postpar.txt' file
#### FTP GET JPG FILE
Get JPG file (~95 KB) from FTP server and save it to file system
* timeout on name lookup is not supported
* Trying 82.196.4.208...
* TCP_NODELAY set
* Connected to loboris.eu (82.196.4.208) port 21 (#0)
< 220 LoBo FTP Server
> AUTH SSL
< 500 AUTH not understood
> AUTH TLS
< 500 AUTH not understood
> USER esp32
< 331 Password required for esp32
> PASS esp32user
< 230 Anonymous access granted, restrictions apply
> PWD
< 257 "/" is the current directory
* Entry path is '/'
> PASV
* Connect data stream passively
* ftp_perform ends with SECONDARY: 0
< 227 Entering Passive Mode (82,196,4,208,192,35).
* Trying 82.196.4.208...
* TCP_NODELAY set
* Connecting to 82.196.4.208 (82.196.4.208) port 49187
* Connected to loboris.eu (82.196.4.208) port 21 (#0)
> TYPE I
< 200 Type set to I
> SIZE tiger240.jpg
< 213 97543
> RETR tiger240.jpg
< 150 Opening BINARY mode data connection for tiger240.jpg (97543 bytes)
* Maxdownload = -1
* Getting file with size: 97543
* Remembering we are in dir ""
< 226 Transfer complete
> QUIT
< 221 Goodbye.
* Closing connection 0
* Download: received 97543 B; time=3.9 s; speed=24.2 KB/sec
____________ Response BODY: ____________
Downloaded to file /spiflash/tiger.jpg, size=97543
^^^^^^^^^^^^ Response BODY: ^^^^^^^^^^^^
#### FTP PUT JPG FILE
Upload received JPG file back to FTP server
* timeout on name lookup is not supported
* Trying 82.196.4.208...
* TCP_NODELAY set
* Connected to loboris.eu (82.196.4.208) port 21 (#0)
< 220 LoBo FTP Server
> AUTH SSL
< 500 AUTH not understood
> AUTH TLS
< 500 AUTH not understood
> USER esp32
< 331 Password required for esp32
> PASS esp32user
< 230 Anonymous access granted, restrictions apply
> PWD
< 257 "/" is the current directory
* Entry path is '/'
> PASV
* Connect data stream passively
* ftp_perform ends with SECONDARY: 0
< 227 Entering Passive Mode (82,196,4,208,192,25).
* Trying 82.196.4.208...
* TCP_NODELAY set
* Connecting to 82.196.4.208 (82.196.4.208) port 49177
* Connected to loboris.eu (82.196.4.208) port 21 (#0)
> TYPE I
< 200 Type set to I
> STOR put_test.jpg
< 150 Opening BINARY mode data connection for put_test.jpg
* We are completely uploaded and fine
* Remembering we are in dir ""
< 226 Transfer complete
> QUIT
< 221 Goodbye.
* Closing connection 0
* Upload: sent 97543 B; time=1.3 s; speed=71.8 KB/sec
____________ Response BODY: ____________
Uploaded file /spiflash/tiger.jpg, size=97543
^^^^^^^^^^^^ Response BODY: ^^^^^^^^^^^^
#### SFTP DOWNLOAD TEXT FILE
Download small text file from SFTP (SSH) server
* timeout on name lookup is not supported
* Trying 195.144.107.198...
* TCP_NODELAY set
* Connected to test.rebex.net (195.144.107.198) port 22 (#0)
* SSH MD5 fingerprint: 0361c498f1ff7d239751071388b8c555
* SSH authentication methods available: password,keyboard-interactive,publickey
* Initialized password authentication
* Authentication complete
* Closing connection 0
____________ Response BODY: ____________
Welcome,
you are connected to an FTP or SFTP server used for testing purposes by Rebex FTP/SSL or Rebex SFTP sample code.
Only read access is allowed and the FTP download speed is limited to 16KBps.
For infomation about Rebex FTP/SSL, Rebex SFTP and other Rebex .NET components, please visit our website at http://www.rebex.net/
For feedback and support, contact support@rebex.net
Thanks!
^^^^^^^^^^^^ Response BODY: ^^^^^^^^^^^^
Received file saved to '/spiflash/sftptest.txt' file
#### SFTP UPLOAD JPG FILE
Upload JPG file to SFTP (SSH) server
* timeout on name lookup is not supported
* Trying 199.71.215.197...
* TCP_NODELAY set
* Connected to demo.wftpserver.com (199.71.215.197) port 2222 (#0)
* SSH MD5 fingerprint: fc9254e606041a978c8ccba772e08652
* SSH authentication methods available: publickey,password
* Initialized password authentication
* Authentication complete
* Upload: sent 16384
* We are completely uploaded and fine
* Closing connection 0
* Upload: sent 97543 B; time=10.0 s; speed=9.6 KB/sec
____________ Response BODY: ____________
Uploaded file /spiflash/tiger.jpg, size=97543
^^^^^^^^^^^^ Response BODY: ^^^^^^^^^^^^
#### SMTP: SEND MAIL
Send email using 'smtp.gmail.com' mail server
* Rebuilt URL to: smtps://smtp.gmail.com:465/
* timeout on name lookup is not supported
* Trying 173.194.76.109...
* TCP_NODELAY set
* Connected to smtp.gmail.com (173.194.76.109) port 465 (#0)
* Error reading ca cert file /certs/ca-certificates.crt - mbedTLS: (-0x3E00) PK - Read/write of file failed
* mbedTLS: Connecting to smtp.gmail.com:465
* mbedTLS: Set min SSL version to TLS 1.0
* mbedTLS: Handshake complete, cipher is TLS-ECDHE-RSA-WITH-AES-128-GCM-SHA256
* Dumping cert info:
* cert. version : 3
* serial number : 44:18:BA:68:73:6E:8D:97
* issuer name : C=US, O=Google Trust Services, CN=Google Internet Authority G3
* subject name : C=US, ST=California, L=Mountain View, O=Google LLC, CN=smtp.gmail.com
* issued on : 2018-04-24 10:35:21
* expires on : 2018-07-17 09:27:00
* signed using : RSA with SHA-256
* RSA key size : 2048 bits
* basic constraints : CA=false
* subject alt name : smtp.gmail.com
* ext key usage : TLS Web Server Authentication
* SSL connected
< 220 smtp.gmail.com ESMTP g105-v6sm19412539wrd.45 - gsmtp
> EHLO localhost
< 250-smtp.gmail.com at your service, [94.253.204.156]
< 250-SIZE 35882577
< 250-8BITMIME
< 250-AUTH LOGIN PLAIN XOAUTH2 PLAIN-CLIENTTOKEN OAUTHBEARER XOAUTH
< 250-ENHANCEDSTATUSCODES
< 250-PIPELINING
< 250-CHUNKING
< 250 SMTPUTF8
> AUTH LOGIN
< 334 VXNlcm5hbWU6
> bG9ib3Jpc0BnbWFpbC5jb20=
< 334 UGFzc3dvcmQ6
> MTQxMkxvQm85NTYzMzAwMDk=
< 235 2.7.0 Accepted
> MAIL FROM:<loboris@gmail.com>
< 250 2.1.0 OK g105-v6sm19412539wrd.45 - gsmtp
> RCPT TO:<loboris@gmail.com>
< 250 2.1.5 OK g105-v6sm19412539wrd.45 - gsmtp
> DATA
< 354 Go ahead g105-v6sm19412539wrd.45 - gsmtp
< 250 2.0.0 OK 1526386974 g105-v6sm19412539wrd.45 - gsmtp
> QUIT
< 221 2.0.0 closing connection g105-v6sm19412539wrd.45 - gsmtp
* Closing connection 0
TIME: 5.0 UP: 131155
OK.
Waiting 49 seconds...
Who is online
Users browsing this forum: Baidu [Spider], Bing [Bot] and 135 guests