Coder Social home page Coder Social logo

automatedtester.browsermob's Introduction

about:me

Chairperson for the W3C Browser Testing and Tools Working Group. Editor of the W3C WebDriver specification. Heading up the Open Source Team at BrowserStack working collaborating on Open Source Projects used BrowserStack and their customers!

  • ๐Ÿ”ญ Iโ€™m currently working on Open Source Projects for BrowserStack.
  • ๐ŸŒฑ Iโ€™m currently improving my Rust knowledge in my spare time.
  • ๐Ÿค” Iโ€™m looking for help on Selenium. If you have time to spare let me know if you want some good first bugs.
  • ๐Ÿ’ฌ Ask me about Engineering Productivity, Browser Automation, Engineering Management
  • ๐Ÿ“ซ How to reach me:

Recent Blog Posts

automatedtester.browsermob's People

Contributors

adathedev avatar automatedtester avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar

automatedtester.browsermob's Issues

Unable to start the browsermob server

Hi,
I have included your source project in my solution and using to start the browsermob proxy, which throws exception since it was unable to start the server. I am using the sample code provided here
Please guide me on how to start the server and necessary requirements to setup browsermob with c#.
Thank you,
Here is the piece of code from Server.cs

           try
           {
               _serverProcess.Start();
               int count = 0;
               while (!IsListening())
               {
                   Thread.Sleep(1000);
                   count++;
                   if (count == 30)
                   {
                       throw new Exception("Can not connect to BrowserMob Proxy");
                   }
               }
           }
           catch
           {
               _serverProcess.Dispose();
               _serverProcess = null;
               throw;
           }       

Cannot retrieve HTTP POST data

I can successfully get URL, size and timing, etc.
But I couldn't get any HTTP request/response content (always null in request.POSTDATA field.)
Anyone knows how to solve this issue?

Thanks!

.Stop() is not stopping

I've been having an issue driving both browsermob-proxy-2.1.0-beta-3 and browsermob-proxy-2.1.0-beta-4 with AutomatedTester namely that .Stop() is not terminating the java side of things nor is it terminating the CMD side of things either.

As a temporary measure, given my naivete, I've modified Stop as follows

    public void Stop()
    {            
        if (_serverProcess != null && !_serverProcess.HasExited)
        {
            _serverProcess.Kill();
            //_serverProcess.CloseMainWindow();
            //_serverProcess.Dispose();
            _serverProcess = null;
        }            
    }

I'm yet to see if this improves things or not. I fancy it leaves a lot of garbage lying around. Is there a better way of making sure that Stop really does Stop? Should I implement Abort and put the Kill in there?

I've also made _serverProcess public so that I can see what the process itself is up to.

Need .Net calls to ReMap the hosts

Can you please provide .Net calls to ReMap the hosts ?
As we have REST API call "POST /proxy/[port]/hosts" but for this we don't have .net wrapped calls.
Can you please help me on this or guide me so I can do this?

License?

Hello, David.
Thanks for this tool!
Sorry, that I contact you by creating this issue (I haven't found another way to do it on gitHub). There is no information about license for browser mob .net wrapper. Can you add one?
Thanks in advance!

Set TrustAllServers for SSL sites

Hi,

I needed to tell browsermob to trustAllServers in order access a local ssl site in the down evnironment with self-signed certs. After reading all the docs about it i could find, i tried to implement a SetTrustAllServers method in Client.cs to model what exists in browsermob. I couldn't get that working; using the same post request as below after the proxy is already started does not seem to have any affect. The SetTrustAllServers method seems to be the best approach since it models how browsermob does it. However for the short term, i was able to get around the issue by modifying the Client ctor to this:

public Client(string url, bool trustAllServers = false)
        {
            if (String.IsNullOrEmpty(url))
                throw new ArgumentException("url not supplied", "url");

            _url = url;
            _baseUrlProxy = String.Format("{0}/proxy", _url);
            var paramters = trustAllServers ? "?trustAllServers=true" : null;

            using (var response = MakeRequest(_baseUrlProxy + paramters, "POST"))
            {...

and then in Server.cs:

public Client CreateProxy(bool trustAllServers = false)
        {
            return new Client(Url, trustAllServers);
        }

If having a TrustAllServers method like browsermob is desired I'll keep at it until I figure it out and submit a pull request--just let me know.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.