Skip to content

Commit

Permalink
Add landing page to favicon page
Browse files Browse the repository at this point in the history
  • Loading branch information
Rafiot committed Feb 19, 2024
1 parent 8b2f875 commit 95a660c
Show file tree
Hide file tree
Showing 3 changed files with 8 additions and 4 deletions.
4 changes: 2 additions & 2 deletions lookyloo/lookyloo.py
Original file line number Diff line number Diff line change
Expand Up @@ -1046,10 +1046,10 @@ def get_cookie_name_investigator(self, cookie_name: str, /) -> tuple[list[tuple[
for domain, freq in self.indexing.get_cookie_domains(cookie_name)]
return captures, domains

def get_favicon_investigator(self, favicon_sha512: str, /) -> tuple[list[tuple[str, str]], bytes | None]:
def get_favicon_investigator(self, favicon_sha512: str, /) -> tuple[list[tuple[str, str, str]], bytes | None]:
'''Returns all the captures related to a cookie name entry, used in the web interface.'''
cached_captures = self.sorted_capture_cache([uuid for uuid in self.indexing.get_captures_favicon(favicon_sha512)])
captures = [(cache.uuid, cache.title) for cache in cached_captures]
captures = [(cache.uuid, cache.title, cache.redirects[-1]) for cache in cached_captures]
favicon = self.indexing.get_favicon(favicon_sha512)
return captures, favicon

Expand Down
6 changes: 5 additions & 1 deletion website/web/templates/favicon_details.html
Original file line number Diff line number Diff line change
Expand Up @@ -16,16 +16,20 @@ <h2>{{ favicon_sha512 }}</h2>
<thead>
<tr>
<th>Capture Title</th>
<th>Landing page</th>
</tr>
</thead>
<tbody>
{% for capture_uuid, title in captures %}
{% for capture_uuid, title, landing_page in captures %}
<tr>
<td>
<a href="{{ url_for('tree', tree_uuid=capture_uuid) }}">
{{ title }}
</a>
</td>
<td>
{{landing_page}}
</td>
</tr>
{% endfor %}
</tbody>
Expand Down
2 changes: 1 addition & 1 deletion website/web/templates/favicons.html
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

{% from 'bootstrap5/utils.html' import render_messages %}

{% block title %}HTTP Headers Hashes lookup{% endblock %}
{% block title %}Favicons lookup{% endblock %}

{% block scripts %}
{{ super() }}
Expand Down

0 comments on commit 95a660c

Please sign in to comment.