> For the complete documentation index, see [llms.txt](https://www.marialc.com/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://www.marialc.com/pentesterlab-labs/recon-badge/recon_08-alt-name.md).

# recon\_08 (alt name)

View the exercise here: [PentesterLab: Recon 08](https://pentesterlab.com/exercises/recon_08/course)

### **OBJECTIVE**

For this challenge, your goal is to access the alternative names in the certificate.

### **ALTERNATIVE NAMES**

When accessing a TLS server, it often pays off to check the content of the certificate used. It's common for TLS servers to have certificates that are valid for more than one name (named alternative names). Looking for alternative names can be done in your client or by using **openssl**.

### **SOLUTION**

In the browser, click the browser settings at the left side of the URL.

Click `Connection is secure` then click `Certificate is valid`.

<figure><img src="/files/J0hhFFvKBlx5rxlrMQBd" alt="" width="563"><figcaption></figcaption></figure>

Select the `Details` tab

<figure><img src="/files/ngVvAXc4pIWLQJ4tQQcs" alt="" width="563"><figcaption></figcaption></figure>

Scroll the `Certificate Fields` list then select `Certificate Subject Alternative Name`

Copy the `DNS Name` field value

<figure><img src="/files/04AZi122eoidtoLMjT5c" alt="" width="563"><figcaption></figcaption></figure>

{% hint style="success" %}
Open it in your browser to get the flag
{% endhint %}

<figure><img src="/files/dmgqvXwmNOF3AZKz89Vw" alt="" width="563"><figcaption></figcaption></figure>

&#x20;

***

**An alternative solution using curl:**

{% hint style="danger" %}
If we use **http**, we’ll obtain the flag for recon 06 ❌
{% endhint %}

<figure><img src="/files/1ld38nSjWixc5gjI9vz0" alt="" width="563"><figcaption></figcaption></figure>

{% hint style="success" %}
We’ll get the recon 08 flag when **https** is used
{% endhint %}

<figure><img src="/files/6VpLJ2GZrIid68lb9AtH" alt="" width="563"><figcaption></figcaption></figure>


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## 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, and the optional `goal` query parameter:

```
GET https://www.marialc.com/pentesterlab-labs/recon-badge/recon_08-alt-name.md?ask=<question>&goal=<endgoal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is optional and describes the broader end goal you are ultimately trying to accomplish on behalf of the user. GitBook uses it to tailor the answer towards what is most useful for that goal.

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.
