Questions tagged [stem]

Stem is a Python controller library for Tor.

Stem is a Python controller library that allows applications to interact with Tor (https://www.torproject.org/).

For tutorials and API documentation see stem’s homepage.

Quick Start

To install you can either use…

pip install stem

… or install from the source tarball. Stem supports both the python 2.x and 3.x series. To use its python3 counterpart you simply need to install using that version of python.

python3 setup.py install

After that, give some tutorials a try! For questions or to discuss project ideas we’re available on irc and the tor-dev@ email list.

104 questions
1
vote
1 answer

Getting new identity with tor and selenium. got error "IncorrectSocketType: unable to use the control socket"

I'm trying to send a 'new identity' signal to tor using the stem module for python. I got most of the code that got me to this point from reading other questions in stackoverflow but I can't seem to find a way to fix this error. I want to be able to…
1
vote
1 answer

Unable to use Stem and Tor in Python to change my IP address?

I am currently trying to follow the a script I found online here: Periodic Tor IP Rotation The code I am trying to use is the following: import requests from stem import Signal from stem.control import Controller with Controller.from_port(port =…
user321627
  • 2,350
  • 4
  • 20
  • 43
1
vote
1 answer

Python - IP not changing with stem?

I wrote a script that changes the IP with stem, but it seems like it does not work. Here is a shortened version of the script: from stem import Signal from stem.control import Controller from stem.connection import connect def changeIP(): with…
user9053402
1
vote
1 answer

Spanish stemming in Oracle Text

I'm trying to create an Oracle Text index to make FTS queries on some text columns in Spanish in the database. According to Oracle docs I need to create a LEXER and a WORDLIST to enable stem and fuzzy queries: exec ctxsys.ctx_ddl.create_preference…
Gabriel Molina
  • 539
  • 3
  • 14
1
vote
1 answer

how to stem each row in csv file?

I have a CSV file with two columns contains sentence. for example Test.csv: Col[1] ---------------------- This trip was amazing. Col[2] -------------------- The cats are playing. so I did some nlp process: with codecs.open('test.csv','r',…
Yousra Gad
  • 363
  • 3
  • 15
1
vote
0 answers

Is there a way to print out TOR IP address via stem library

Is there anyway to print out the IP address that is generated by TOR, to ensure that it is not using my IP address? Here is my code: from stem import Signal from stem.control import Controller def tor_connection(): with…
user3062459
  • 1,587
  • 7
  • 27
  • 39
1
vote
1 answer

How to enable stem language in php?

I have installed porter stemmer: pecl install stem ... Compile Danish stemmer? [yes] : n Compile Dutch stemmer? [yes] : n Compile English stemmer? [yes] : y Compile Finnish stemmer? [yes] : n Compile French stemmer? [yes] : n Compile German…
kz_sergey
  • 677
  • 5
  • 19
1
vote
1 answer

How to create a stem-leaf plot in R from txt file?

I am BRAND new to R. I need help creating a simple stem-leaf plot in R. This is my data to create the stem-leaf plot. It is saved in an text file. THIS IS HOW I WANT MY STEM TO LOOK-LEAF LIKE. Stem Leaf 0 1 1 2 2 3 3 4 4 5 5 5 5 6 6 6 7 8 8 8 8…
user372204
  • 69
  • 2
  • 10
1
vote
1 answer

Number of connections to tor via stem library - Controller creates 2 connections but closing the controller removes only one connection

I am working with the stem library and I'm writing a thin wrapper over the Stem Controller class. I have some questions relating to the number of connections created when a controller is instantiated and how many are removed when the controller is…
mayk93
  • 1,489
  • 3
  • 17
  • 31
1
vote
1 answer

Changing identity using Tor and Stem

I'm following the tutorial To Russia With Love, and as part of this I want to change the identity everytime I run the code. I've looked at multiple questions and tutorials and from the looks of it my torrc-defaults file is correct as it has:…
April
  • 35
  • 5
1
vote
0 answers

get_circuits() of Stem library returns an empty list

When I execute controller.get_circuits(), I get an empty list. How could this be? with stem.control.Controller.from_port(port=9151) as controller: controller.authenticate() controller.signal(Signal.NEWNYM) # get new tor identity circs =…
surbhi
  • 387
  • 5
  • 16
1
vote
3 answers

How to get the Tor ExitNode IP with Python and Stem

I'm trying to get the external IP that Tor uses, as mentioned here. When using something like myip.dnsomatic.com, this is very slow. I tried what was suggested in the aforementioned link (python + stem to control tor through the control port), but…
AlbertoG
  • 11
  • 1
  • 4
1
vote
0 answers

How to detect that NYM is changed

I use Stem for controlling my tor. I need to know when tor changes it's IP. It usually happens when signal NEWNYM is sended to tor, but there can be some other reasons. Maybe, easiest way is to check current tor IP and user-agent. But I don't know…
Antonio
  • 822
  • 1
  • 10
  • 19
0
votes
0 answers

How do I draw stems or Line3d on a 3d plot with a background image?

I have a background picture on my 3d plot. I want to draw Line using stem or Line3D on top of the image. But stem got covered by the image. How to solve this? # Controls for print and animation i_Shape3d = 1 # Set Shape of 3d Plot:…
0
votes
0 answers

Gaurd Node in torrc file

Hello I have some questions related to tor. How to disable Guard node in torrc file or by using stem Is there any method in stem where I can specify my Exit Node. I know a method in torrc file but I don't know how to do it in stem or using…
Bahi
  • 3
  • 2