Jugendhackt / haskell-ricochet

(WIP/Experimental) Ricochet implementation as Haskell Library.
GNU General Public License v3.0
22 stars 0 forks source link

Implement the monadic run functions #36

Closed froozen closed 9 years ago

froozen commented 9 years ago

As you can see, there's still the problem on how to handle the. I think there are two options here:

Another thing is, that startRicochet doesn't really need to be passed the SOCKS port, as it can query it over the control socket. Unfortunately, this doesn't seem to be working properly, so I'll be taking a look at that and change it as soon as it's fixed.

sternenseemann commented 9 years ago

I'd stick with PortID as it is the nice high-level way to handle ports in Haskell.

You'll have to Pull-Reqeust network-anonymous-tor anyways :stuck_out_tongue:

froozen commented 9 years ago

So, I did some research, and it seems like the Tor Control Socket currently doesn't support any non-digit ports to forward to. I added support for Services, but I don't think I'll get UNIX socket support working as long as the Tor Project doesn't. Should I just add the lack of support to the the haddock comment or do we want to change the API?

sternenseemann commented 9 years ago

I'd document the lack of support (also one would have to configure the tor control socket first).

Then, I'd report it upstream to the Tor project and ask them what they think about a control unix socket!

sternenseemann commented 9 years ago

I have written to the tor-talk mailing list. I will report back.

sternenseemann commented 9 years ago

What were you guys talking about? Of course we need PortID:

torrc(5):

 ControlSocket Path
      Like ControlPort, but listens on a Unix domain socket, rather than a TCP
      socket.  0 disables ControlSocket (Unix and Unix-like systems only.)
photm5 commented 9 years ago

We’re not talking about controlling the Tor daemon via unix sockets. It’s about forwarding ports from the hidden service to a unix socket, instead of a port number.

sternenseemann commented 9 years ago

Support for that could show up though…

froozen commented 9 years ago

It's already supported from the torrc, but not via the control socket. I'm sure it'll be implemented at some point. We could open up an issue for this, but I don't think waiting with this merge until it happens would be a good idea.

sternenseemann commented 9 years ago

Best Idea is to keep using PortID and then wait & see.

froozen commented 9 years ago

I think so too. I won't do a PR for PortIDs over at network-anonymous-tor until they are fully supported by Tor, though.

sternenseemann commented 9 years ago

I second that decision.

froozen commented 9 years ago

This still leaves the issue with the amount of arguments @shak-mar pointed out. Do we just make the user assemble RicochetState themselves?

froozen commented 9 years ago

So what's the opinion on this PR? Anything that should be changed or is it ready for merging?

photm5 commented 9 years ago

I think it’s ready for merging. We can still change stuff later.

sternenseemann commented 9 years ago

:+1:

froozen commented 9 years ago

Well, I'll have to resolve some conflicts first, it seems.

photm5 commented 9 years ago

I didn’t try out your fold stuff in shell.nix until now, and it doesn’t work for me!

froozen commented 9 years ago

From the nature of the error, I'd guess we're using different versions of nix and that causes this problem. What exactly is the error you're getting? Also, @lukasepple does it work for you?

photm5 commented 9 years ago

I’m not getting a nix error, but the version of hptoroc is 2.1.6 instead of 2.1.7, which makes the cabal configure phase fail:

unrecognized option `--lenses'

Usage: …

I don’t see how this could be caused by different nix versions.

sternenseemann commented 9 years ago

master builds for me just fine right now.