{"schema":"libjg2-1",
"vpath":"/git/",
"avatar":"/git/avatar/",
"alang":"",
"gen_ut":1731526687,
"reponame":"libwebsockets",
"desc":"libwebsockets lightweight C networking library",
"owner": { "name": "Andy Green", "email": "andy@warmcat.com", "md5": "c50933ca2aa61e0fe2c43d46bb6b59cb" },"url":"https://libwebsockets.org/repo/libwebsockets",
"f":3,
"items": [
{ "schema":"libjg2-1",
"oid":{ "oid": "6328231f2aa628632344d96a58e25c3b194af506", "alias": [ "refs/heads/main"]},"tree": [
{ "name": "CMakeLists.txt","mode": "33188", "size":7077},
{ "name": "README.md","mode": "33188", "size":3938},
{ "name": "minimal-http-client.c","mode": "33188", "size":11164},
{ "name": "warmcat.com.cer","mode": "33188", "size":1940},
{ "name": "wrong.cer","mode": "33188", "size":1189}],"s":{"c":1731526687,"u": 1225}}
,{"schema":"libjg2-1",
"cid":"bd8a6ac24ea2f8adb8351cf614ccd9db",
"oid":{ "oid": "6328231f2aa628632344d96a58e25c3b194af506", "alias": [ "refs/heads/main"]},"blobname": "minimal-examples-lowlevel/http-client/minimal-http-client/README.md", "blob": "# lws minimal http client\n\nThe application goes to either https://warmcat.com or\nhttps://localhost:7681 (with `-l` option) and receives the page data.\n\n## build\n\n```\n $ cmake . \u0026\u0026 make\n```\n\n## usage\n\nCommandline option|Meaning\n---|---\n-d \u003cloglevel\u003e|Debug verbosity in decimal, eg, -d15\n-l| Connect to https://localhost:7681 and accept selfsigned cert\n--h1|Specify http/1.1 only using ALPN, rejects h2 even if server supports it\n--server \u003cname\u003e|set server name to connect to\n-k|Apply tls option LCCSCF_ALLOW_INSECURE\n-j|Apply tls option LCCSCF_ALLOW_SELFSIGNED\n-m|Apply tls option LCCSCF_SKIP_SERVER_CERT_HOSTNAME_CHECK\n-e|Apply tls option LCCSCF_ALLOW_EXPIRED\n-b|Apply tls option LCCSCF_CACHE_COOKIES\n-w|For mbedtls/wolfssl, load wrong CA cert (expected to fail)\n-c \u003ccookie jar file\u003e|Set filepath used for cookie jar\n-v|Connection validity use 3s / 10s instead of default 5m / 5m10s\n--nossl| disable ssl connection\n--user \u003cusername\u003e| Set Basic Auth username\n--password \u003cpassword\u003e | Set Basic Auth password\n\n```\n $ ./lws-minimal-http-client\n[2018/03/04 14:43:20:8562] USER: LWS minimal http client\n[2018/03/04 14:43:20:8571] NOTICE: Creating Vhost 'default' port -1, 1 protocols, IPv6 on\n[2018/03/04 14:43:20:8616] NOTICE: created client ssl context for default\n[2018/03/04 14:43:20:8617] NOTICE: lws_client_connect_2: 0x1814dc0: address warmcat.com\n[2018/03/04 14:43:21:1496] NOTICE: lws_client_connect_2: 0x1814dc0: address warmcat.com\n[2018/03/04 14:43:22:0154] NOTICE: lws_client_interpret_server_handshake: incoming content length 26520\n[2018/03/04 14:43:22:0154] NOTICE: lws_client_interpret_server_handshake: client connection up\n[2018/03/04 14:43:22:0169] USER: RECEIVE_CLIENT_HTTP_READ: read 1024\n[2018/03/04 14:43:22:0169] USER: RECEIVE_CLIENT_HTTP_READ: read 1024\n[2018/03/04 14:43:22:0169] USER: RECEIVE_CLIENT_HTTP_READ: read 1024\n[2018/03/04 14:43:22:0169] USER: RECEIVE_CLIENT_HTTP_READ: read 1015\n[2018/03/04 14:43:22:0174] USER: RECEIVE_CLIENT_HTTP_READ: read 1024\n[2018/03/04 14:43:22:0174] USER: RECEIVE_CLIENT_HTTP_READ: read 1024\n[2018/03/04 14:43:22:0174] USER: RECEIVE_CLIENT_HTTP_READ: read 1024\n[2018/03/04 14:43:22:0174] USER: RECEIVE_CLIENT_HTTP_READ: read 1015\n[2018/03/04 14:43:22:0179] USER: RECEIVE_CLIENT_HTTP_READ: read 1024\n[2018/03/04 14:43:22:0179] USER: RECEIVE_CLIENT_HTTP_READ: read 1024\n[2018/03/04 14:43:22:0179] USER: RECEIVE_CLIENT_HTTP_READ: read 1024\n[2018/03/04 14:43:22:0179] USER: RECEIVE_CLIENT_HTTP_READ: read 1015\n[2018/03/04 14:43:22:3010] USER: RECEIVE_CLIENT_HTTP_READ: read 1024\n[2018/03/04 14:43:22:3010] USER: RECEIVE_CLIENT_HTTP_READ: read 1024\n[2018/03/04 14:43:22:3010] USER: RECEIVE_CLIENT_HTTP_READ: read 1024\n[2018/03/04 14:43:22:3010] USER: RECEIVE_CLIENT_HTTP_READ: read 1015\n[2018/03/04 14:43:22:3015] USER: RECEIVE_CLIENT_HTTP_READ: read 1024\n[2018/03/04 14:43:22:3015] USER: RECEIVE_CLIENT_HTTP_READ: read 1024\n[2018/03/04 14:43:22:3015] USER: RECEIVE_CLIENT_HTTP_READ: read 1024\n[2018/03/04 14:43:22:3015] USER: RECEIVE_CLIENT_HTTP_READ: read 1015\n[2018/03/04 14:43:22:3020] USER: RECEIVE_CLIENT_HTTP_READ: read 1024\n[2018/03/04 14:43:22:3020] USER: RECEIVE_CLIENT_HTTP_READ: read 1024\n[2018/03/04 14:43:22:3020] USER: RECEIVE_CLIENT_HTTP_READ: read 1024\n[2018/03/04 14:43:22:3020] USER: RECEIVE_CLIENT_HTTP_READ: read 1015\n[2018/03/04 14:43:22:3022] USER: RECEIVE_CLIENT_HTTP_READ: read 1024\n[2018/03/04 14:43:22:3022] USER: RECEIVE_CLIENT_HTTP_READ: read 974\n[2018/03/04 14:43:22:3022] NOTICE: lws_http_client_read: transaction completed says -1\n[2018/03/04 14:43:23:3042] USER: Completed\n```\n\nYou can also test the client Basic Auth support against the http-server/minimal-http-server-basicauth\nexample. In one console window run the server and in the other\n\n```\n$ lws-minimal-http-client -l --nossl --path /secret/index.html --user user --password password\n```\n\nThe Basic Auth credentials for the test server are literally username \u0022user\u0022 and password \u0022password\u0022.\n\n","s":{"c":1731526687,"u": 467}}
],"g": 4353,"chitpc": 0,"ehitpc": 0,"indexed":0
,
"ab": 1, "si": 0, "db":0, "di":1, "sat":0, "lfc": "0000"}