Documentation
¶
Overview ¶
Package radiance provides a local server that proxies all requests to a remote proxy server using different protocols meant to circumvent censorship. Radiance uses a [transport.StreamDialer] to dial the target server over the desired protocol. The config.Config is used to configure the dialer for a proxy server.
Index ¶
- type IssueReport
- type Options
- type Radiance
- func (r *Radiance) APIHandler() *api.APIClient
- func (r *Radiance) AddConfigListener(onChange func())deprecated
- func (r *Radiance) Close()
- func (r *Radiance) Features() map[string]bool
- func (r *Radiance) ReportIssue(email string, report IssueReport) error
- func (r *Radiance) ServerLocations() ([]lcommon.ServerLocation, error)
- func (r *Radiance) ServerManager() *servers.Manager
- func (r *Radiance) SetPreferredServer(ctx context.Context, country, city string)
- func (r *Radiance) UserInfo() common.UserInfo
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type IssueReport ¶
type IssueReport = issue.IssueReport
type Radiance ¶
type Radiance struct {
// contains filtered or unexported fields
}
Radiance is a local server that proxies all requests to a remote proxy server over a transport.StreamDialer.
func NewRadiance ¶
NewRadiance creates a new Radiance VPN client. opts includes the platform interface used to interact with the underlying platform on iOS, Android, and MacOS. On other platforms, it is ignored and can be nil.
func (*Radiance) APIHandler ¶
APIHandler returns the API handler for the Radiance client.
func (*Radiance) AddConfigListener
deprecated
func (r *Radiance) AddConfigListener(onChange func())
AddConfigListener adds a listener that is called whenever the configuration changes.
Deprecated: Use events handler subscriptions instead.
func (*Radiance) Features ¶
Features returns the features available in the current configuration, returned from the server in the config response.
func (*Radiance) ReportIssue ¶
func (r *Radiance) ReportIssue(email string, report IssueReport) error
ReportIssue submits an issue report to the back-end with an optional user email
func (*Radiance) ServerLocations ¶
func (r *Radiance) ServerLocations() ([]lcommon.ServerLocation, error)
ServerLocations returns the list of server locations where the user can connect to proxies.
func (*Radiance) ServerManager ¶
ServerManager returns the server manager for the Radiance client.
func (*Radiance) SetPreferredServer ¶
SetPreferredServer sets the preferred server location for the VPN connection. pass empty strings to auto select the server location
Directories
¶
| Path | Synopsis |
|---|---|
|
Package common contains common initialization code and utilities for the Radiance application.
|
Package common contains common initialization code and utilities for the Radiance application. |
|
atomicfile
Package atomicfile provides functions to read and write files atomically.
|
Package atomicfile provides functions to read and write files atomically. |
|
env
Package env is responsible for loading radiance configuration based on a order of precedence (environment variables > configurations set at .env file).
|
Package env is responsible for loading radiance configuration based on a order of precedence (environment variables > configurations set at .env file). |
|
Package config provides a handler for fetching and storing proxy configurations.
|
Package config provides a handler for fetching and storing proxy configurations. |
|
Package events provides a simple publish-subscribe mechanism for event handling.
|
Package events provides a simple publish-subscribe mechanism for event handling. |
|
Package servers provides management of server configurations, such as option.Endpoints and option.Outbounds,and integration with remote server managers for adding, inviting, and revoking private servers with trust-on-first-use (TOFU) fingerprint verification.
|
Package servers provides management of server configurations, such as option.Endpoints and option.Outbounds,and integration with remote server managers for adding, inviting, and revoking private servers with trust-on-first-use (TOFU) fingerprint verification. |
|
Package telemetry provides OpenTelemetry setup for radiance
|
Package telemetry provides OpenTelemetry setup for radiance |
|
Package traces provides utilities for working with OpenTelemetry traces.
|
Package traces provides utilities for working with OpenTelemetry traces. |
|
Package vpn provides high-level management of VPN tunnels, including connecting to the best available server, connecting to specific servers, disconnecting, reconnecting, and querying tunnel status.
|
Package vpn provides high-level management of VPN tunnels, including connecting to the best available server, connecting to specific servers, disconnecting, reconnecting, and querying tunnel status. |
|
ipc
Package ipc implements the IPC server for communicating between the client and the VPN service.
|
Package ipc implements the IPC server for communicating between the client and the VPN service. |