added support for tor entry/exit countries
This commit is contained in:
@@ -136,6 +136,8 @@ class TorProxyService extends _$TorProxyService {
|
||||
null => TransportType.none,
|
||||
},
|
||||
bridgeLines: setting?.bridge.bridges ?? [],
|
||||
entryNodeCountries: torSettings.entryNodeCountry?.toLowerCase(),
|
||||
exitNodeCountries: torSettings.exitNodeCountry?.toLowerCase(),
|
||||
);
|
||||
|
||||
await _tor.start(config);
|
||||
@@ -155,6 +157,10 @@ class TorProxyService extends _$TorProxyService {
|
||||
await _tor.stop();
|
||||
}
|
||||
|
||||
Future<void> requestNewIdentity() async {
|
||||
await _tor.requestNewIdentity();
|
||||
}
|
||||
|
||||
@override
|
||||
Stream<TorStatus> build() {
|
||||
_statusSyncController = StreamController();
|
||||
|
||||
@@ -33,7 +33,7 @@ final class TorProxyServiceProvider
|
||||
TorProxyService create() => TorProxyService();
|
||||
}
|
||||
|
||||
String _$torProxyServiceHash() => r'be69327bdef8feaa2a43bd83f20168988dcdd228';
|
||||
String _$torProxyServiceHash() => r'0bf00b61bf7e739fe8c77696cf1b2a151d137671';
|
||||
|
||||
abstract class _$TorProxyService extends $StreamNotifier<TorStatus> {
|
||||
Stream<TorStatus> build();
|
||||
|
||||
Reference in New Issue
Block a user