Giter VIP home page Giter VIP logo

Comments (8)

klzgrad avatar klzgrad commented on May 26, 2024

example.com/xxx/trojan - you are trying to suggest using some part of the http request as the authentication token. I think an http header is more suitable for this purpose. In the new mode (in development) of the Trojan protocol we will use proxy-authorization for this.

Websocket involves extra protocol round trips compared to HTTPS or raw TLS with no real benefits for tunneling. QUIC is a possible alternative transport to HTTP/2, but only after it is standardized, deployed in Chrome, and has server implementations.

from trojan.

antonchen avatar antonchen commented on May 26, 2024

@klzgrad My point is: example.com/xxx/trojan to hide trojan In a web site, https encrypted outside the path can not be obtained, GFW only know example.com do not know trojan.
The purpose is not authentication, is hidden trojan.

Websocket is my error.

from trojan.

klzgrad avatar klzgrad commented on May 26, 2024

example.com without auth header -> masquerade website

example.com with auth header -> proxy

This is all "content switching" or load balancing using part of the request as the key. Only difference is to use which part, the url or a header.

from trojan.

antonchen avatar antonchen commented on May 26, 2024

@klzgrad I understand.

About proxy-authorization
Will the proxy-authorization verification by whom?
What I'm worried about is:Unauthenticated request use proxy-authorization header, trojan return what?

from trojan.

klzgrad avatar klzgrad commented on May 26, 2024

Verified by a Trojan server.

If unauthenticated, the Trojan server returns the masquerade website.

from trojan.

antonchen avatar antonchen commented on May 26, 2024

@klzgrad

How to return to the masquerade website? If it is 301 or 302 that formed a feature

Seems to be back to my earliest question.

The correct URL to trojan check proxy-authorization
The wrong URL can never find trojan

The goal is to reduce trojan's connection to unknown requests

So I think custom URL is useful.

PS:Whether there is a telegraph group, English is not good, discuss some difficult.

from trojan.

klzgrad avatar klzgrad commented on May 26, 2024

In Nginx's language,

server {
    ...
    set $upstream "masquerade";
    if ($http_proxy_authorization ~ "Basic aGVsbG86d29ybGQ=") {
        set $upstream "proxy";                                   
    }

    location / {
        proxy_pass $upstream
    }
}

This makes the goal you defined too.

from trojan.

antonchen avatar antonchen commented on May 26, 2024

@klzgrad Got it, thanks for the answer. Look forward to the new version.

from trojan.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.