# CLI Tool to interact with HTTP/HTTPS

### Http Interaction (Netcat)

You can interact with an http website using netcat

```bash
$ nc -v elearnsecurity.com 80
GET / HTTP/1.1
Host: www.elearnsecurity.com

--Response--
```

***

### Https Interaction (Openssl)

Since, netcat does not support ssl/tls, we use openssl client to interact with https enabled websites.

```bash
$ openssl s_client -connect elearnsecurity.com:443
GET / HTTP/1.1
Host: www.elearnsecurity.com

--Response--
```

Some interesting openssl flags are -quiet to disable handshake showing and -debug to see the handshake details

You can also use `OPTIONS / HTTP/1.1` to see all the available options that website accepts.

***


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://notes.nomanaziz.me/cybersecurity/penetration-testing/elearnsecurity/ejpt/networking/cli-tool-to-interact-with-http-https.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
