1.0.11 • Published 12 months ago

@petersteele/tor-manager v1.0.11

Weekly downloads
-
License
ISC
Repository
-
Last release
12 months ago

tor-manager

What is this package for?

This package makes it easy to use tor binary with bridges or without.

How to use

  1. Download tor expert bundle from https://www.torproject.org/download/tor
  2. Extract two folders (data, tor) in the same folder in your project.
  3. Initialize it with initTor(<path_to_tor_binary>)
  4. Run tor using enableTor()

Possible project structure

|— package.json
|— index.js
|— tor
    |
    |— tor 
    |   |
    |   tor.exe
    |   pluggable_transports
    |
    |— data
    |   |
    |   geoip
    |   geoip6

Arguments

bridge

Allows to specify bridge type which tor will use

enableTor({bridge: BridgeType.Obfs4})
// Bridges: BridgeType.Obfs4, BridgeType.Snowflake, BridgeType.MeekAzure

onLog

Callback for tor logs

enableTor({
    onLog: (message) => {
        console.log(message)
    }
})

country

Allows to specify country code (if not provided, it will be defined automatically)

enableTor({country: "us"})

timeout

Sets timeout after which tor will be disabled

enableTor({timeout: 10000})
1.0.11

12 months ago

1.0.10

12 months ago

1.0.9

12 months ago

1.0.8

12 months ago

1.0.7

12 months ago

1.0.6

12 months ago

1.0.5

12 months ago

1.0.4

12 months ago

1.0.3

12 months ago

1.0.2

12 months ago

1.0.1

12 months ago

1.0.0

12 months ago