Jump to content
Search In
  • More options...
Find results that contain...
Find results in...

Welcome to our site

Take a moment to join our board

Sign in to follow this  
Zen

[Question] C++ socket/GUI libraries recommendations

Recommended Posts

Hi guys,

In order to start a PoC of my Conquer Man In The Middle program, I'm looking for some C++ libraries to use. The library/ies should be able to handle at least networking and GUI management.

I've had some experiences with the SFML library that included modules for both of my needs, but I'd be interested in testing new things.
I think that a majority of you are C# or Go programmers (from what I read), but maybe you've got insights from your experience or your friends.

What would you recommend? I've read a lot from the Internet, and found many resources here and there. My motto is "the lighter the better", as I am not looking for great performance as of now. Cross platform would be neat.

Thanks guys!

EDIT : by the way, if you think of another aspect that would require the use of a library like threads, please let me know! :)

Edited by Zen

Share this post


Link to post
Share on other sites

Happy to see another person interested in C++

for networking I prefer to use boost.asio I like the way they handle asynchronous sockets and they are up to date and use newer c++ features , I'd say use boost generally since they have a lot of different libraries that can go along way helping you develop with c++ , it's also very well documented.

as for GUI I can't really suggest a library since I use winapi when I rarely need to do UI work but I would say Qt is one of the better options.

Good luck with your coding adventures.

  • Thanks 1

Share this post


Link to post
Share on other sites

Hello @Diab,

nice to meet you here, and thank you for your reply.

I was about to consider boost.asio for the networking part as I've read lots of good from this library, so it's nice to have further recommendations for it here.

Regarding the GUI, of course I am aware of Qt, but I thought about using something lighter. From what I've heard, Qt is relatively heavy and makes the coffee. But thank you anyway for the idea!

Thank you again mate.

Share this post


Link to post
Share on other sites

I work in C++ professionally and we primarily use Qt for our GUIs. It's a large framework as you said, but it's portable and full featured. You could try GTK, but my understanding is that it's not that much better. At home, I just use a console for my service apps. If I really need a front-end UI, then I usually make a responsive web client and web API server that talks RPC to my other services. It ends up being a bit nicer to use since there're so many responsive UI frameworks out there. If you're looking for a super clean C++ Socket library, then I highly recommend libuv. It implements os-specific socket event loops like completion ports, epoll, and kqueues for you, which is nice if you're looking to make a cross-platform proxy.

  • Thanks 1

Share this post


Link to post
Share on other sites

Hi @Spirited,

Thank you for sharing your inputs.

Actually, for my PoC, I wanted something light to use because the idea is to spend more time on the features rather than to ease the interaction/visualization in the first place. I wanted to have a console version of the PoC when I first thought about it, but my issue is that any interaction with the user is blocking (as far as I have experienced it). Meaning, if I want the ability to run commands, I need to have a std::cin somewhere waiting to be filled-in with inputs, but in this case, any data-display will be broken as you can probably imagine. Or, maybe I could spawn another "console interface" but if it means having two separate processes, I do not really feel like implementing inter-process communication for the PoC. That's why I think it would be probably better to use a GUI library.
I'll check GTK and Qt anyway, thanks! I'm not really into web developpement and I have no idea how to handle RPCs so I will less consider this option, but thanks a lot for whispering the idea!

I have never heard of libuv and indeed, I'd really like to have a cross-platform code so might consider this one, although I have already prepared the project with boost.asio by now.

Thank you again for your reply!

 

 

 

Share this post


Link to post
Share on other sites

I can't say I have much experience with any networking libraries in C++, but I have worked with QT before. As others have stated above, Qt is pretty known and has quite a bit of documentation. I have done something similar to what @Spirited did with RPC. I just had my program use gRPCs to communicate with the web front-end. However, it seems like from reading this thread QT might be your best bet if you don't want to spend too much time learning new stuff for marginal gains.

  • Thanks 1

Share this post


Link to post
Share on other sites

 Hi @Smallxmac,

Thank you for sharing your thoughts here. I really like the idea from both of you, which would be to use RPC to control the state of the Proxy Bot. But for now, as an absolute beginner on both RPC and Conquer MITM programming topics, I guess I'll stick to doing things "conventionally". It's my shot to have a code as modular as possible to permit its evolution and possibly integrate the use of RPC. I will probably learn a lot from this PoC and from you too.

Thanks again Smallxmac and all for your posts.

 

Edited by Zen

Share this post


Link to post
Share on other sites

I don't necessarily recommend a separate executable for a web server that speaks to a proxy server via RPC. You can host a web server as part of the proxy. A lot of entry level server apps do that now, and I'm a huge fan. If you went with a web server, suddenly you can make your proxy a docker image that people can just download and use immediately, and not just on their system but any system (like a Raspberry Pi Zero that can be controlled via the proxy's web portal). I think adding a traditional GUI might make your proxy less usable by comparison, but maybe I'm of a very niche mindset.

  • Thanks 1

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
Sign in to follow this  

×

Important Information

By using this site, you agree to our Terms of Use.