Skip to content

[BUG] Server Transmits Code in Cleartext - No TLS Support #75

@EnthusiasticTech

Description

@EnthusiasticTech

Project

vgrep

Description

The vgrep server only supports plain HTTP with no option for TLS/HTTPS. When the server is bound to a non-localhost interface (e.g., VGREP_HOST=0.0.0.0), all traffic including indexed code content is transmitted in cleartext, allowing network eavesdropping.

Error Message

Debug Logs

System Information

Bounty Version: 0.1.0
OS: Ubuntu 24.04 LTS
CPU: AMD EPYC-Genoa Processor (8 cores)
RAM: 15 GB

Screenshots

No response

Steps to Reproduce

  1. Start server on all interfaces:
VGREP_HOST=0.0.0.0 vgrep serve
  1. From another machine, capture traffic:
tcpdump -i eth0 port 7777 -A
  1. Make a search request - observe code snippets are visible in packet capture

Expected Behavior

The server should support TLS/HTTPS, either:

  1. Built-in TLS support with certificate configuration
  2. Documentation for using a reverse proxy (nginx/caddy) with TLS

Actual Behavior

Server only supports plain HTTP:

// src/server/api.rs line 125-126
let listener = tokio::net::TcpListener::bind(addr).await?;
axum::serve(listener, app).await?;
// No TLS configuration

Additional Context

No response

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't workingvalidValid issuevgrep

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions