Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 7969595
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 4, 20262026-06-04T07:15:39+00:00 2026-06-04T07:15:39+00:00

I have a twisted proxy from here: Python Twisted proxy – how to intercept

  • 0

I have a twisted proxy from here: Python Twisted proxy – how to intercept packets .

It prints the HTTP data, and I would like also to intercept and examine the raw IP datgrams. How to hook the callback for the IP packets?

http://twistedmatrix.com/documents/11.0.0/api/twisted.pair.ip.IPProtocol.html

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-04T07:15:40+00:00Added an answer on June 4, 2026 at 7:15 am

    Twisted doesn’t have a built-in friendly way to hook in a listener on a raw IP socket (SOCK_RAW). This is for several reasons:

    • using SOCK_RAW can be tricky and it can work in non-obvious ways;
    • in most environments, using such a socket requires elevated privileges;
    • and the packets you actually get through a raw socket differ a lot between operating systems (e.g., you won’t get any raw TCP-protocol IP packets on *BSD/Darwin through a raw socket, even if you’re root).

    The best way to capture raw datagrams in general, in a remotely portable manner, is with libpcap. Here is a link to someone who appears to have combined pcap and Twisted in a reasonably intelligent way; that may help.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

How can I create a non-http proxy with Twisted. Instead I would like to
I downloaded Punjab from Github . I also have Python 2.7, Twisted Python 10.2,
Recently I have been playing around with the HTTP Proxy in twisted. After much
I have been running this code (from: http://blog.somethingaboutcode.com/?p=155 ): from twisted.internet import reactor from
I would like to run a small http proxy server on my machine which
I am using python twisted module to intercept headers. I have the following script:
I have to create a python (twisted) application that accepts connections from clients via
I have a problem with using Twisted for simple concurrency in python. The problem
I have an XMPP server (likely — python, twisted, wokkel), which I prefer not
I have the following python code using the twisted API. def function(self,filename): def results(result):

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.