{ "info": { "author": "Alessandro Maggio", "author_email": "me@alessandromaggio.com", "bugtrack_url": null, "classifiers": [ "Development Status :: 5 - Production/Stable", "Intended Audience :: System Administrators", "Natural Language :: English" ], "description": "# pythonping\nPythonPing is simple way to ping in Python. With it, you can send ICMP Probes to remote devices like you would do from the terminal. PythonPing is modular, so that you can run it in a script as a standalone function, or integrate its components in a fully-fledged application.\n\n## Basic Usage\nThe simplest usage of PythonPing is in a script. You can use the `ping` function to ping a target. If you want to see the output immediately, emulating what happens on the terminal, use the `verbose` flag as below.\n```python\nfrom pythonping import ping\n\n\nping('127.0.0.1', verbose=True)\n```\nThis will yeld the following result.\n```\nReply from 127.0.0.1, 9 bytes in 0.17ms\nReply from 127.0.0.1, 9 bytes in 0.14ms\nReply from 127.0.0.1, 9 bytes in 0.12ms\nReply from 127.0.0.1, 9 bytes in 0.12ms\n```\nRegardless of the verbose mode, the `ping` function will always return a `ResponseList` object. This is a special iterable object, containing a list of `Response` items. In each response, you can find the packet received and some meta information, like the time it took to receive the response and any error message.\nYou can also tune your ping by using some of its additional parameters:\n* `size` is an integer that allows you to specify the size of the ICMP payload you desire\n* `timeout` is the number of seconds you wish to wait for a response, before assuming the target is unreachable\n* `payload` allows you to use a specific payload (bytes)\n* `count` specify allows you to define how many ICMP packets to send\n* `sweep_start` and `sweep_end` allows you to perform a ping sweep, starting from payload size defined in `sweep_start` and growing up to size defined in `sweep_end`. Here, we repeat the payload you provided to match the desired size, or we generate a random one if no payload was provided. Note that if you defined `size`, these two fields will be ignored\n* `df` is a flag that, if set to True, will enable the *Don't Fragment* flag in the IP header\n* `verbose` enables the verbose mode, printing output to a stream (see `out`)\n* `out` is the target stream of verbose mode. If you enable the verbose mode and do not provide `out`, verbose output will be send to the `sys.stdout` stream. You may want to use a file here, for example.\n\n## Advanced Usage\nIf you wish to extend PythonPing, or integrate it in your application, we recommend to use the classes that are part of Python Ping instead of the `ping` function.\n`executor.Communicator` handles the communication with the target device, it takes care of sending ICMP requests and processing responses. It ultimately produces the `executor.ResponseList` object. The `Communicator` needs to know a target and which payloads to send to the remote device. For that, we have several classes in the `payload_provider` module. You may want to create your own provider by extending `payload_provider.PayloadProvider`. If you are interested in that, you should check the documentation of both `executor` and `payload_provider` module.", "description_content_type": "text/markdown", "docs_url": null, "download_url": "", "downloads": { "last_day": -1, "last_month": -1, "last_week": -1 }, "home_page": "https://github.com/alessandromaggio/pythonping", "keywords": "ping,icmp,network", "license": "MIT", "maintainer": "", "maintainer_email": "", "name": "pythonping", "package_url": "https://pypi.org/project/pythonping/", "platform": "", "project_url": "https://pypi.org/project/pythonping/", "project_urls": { "Homepage": "https://github.com/alessandromaggio/pythonping" }, "release_url": "https://pypi.org/project/pythonping/1.0.5/", "requires_dist": null, "requires_python": "", "summary": "A simple way to ping in Python", "version": "1.0.5" }, "last_serial": 5767333, "releases": { "0.1": [ { "comment_text": "", "digests": { "md5": "35a181176e0b6afe89256d3edd28c895", "sha256": "e1afdca7e36c9aa97f6a42e3397607bdc932cdd8a81dcebd2c22f57b7d0e0795" }, "downloads": -1, "filename": "pythonping-0.1.tar.gz", "has_sig": false, "md5_digest": "35a181176e0b6afe89256d3edd28c895", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 6096, "upload_time": "2018-03-24T16:47:20", "url": "https://files.pythonhosted.org/packages/a0/6a/0e184852899330aafb4ebcc690717ea61d9489fb2b46bad173f6ad5fa8aa/pythonping-0.1.tar.gz" } ], "1.0.0": [ { "comment_text": "", "digests": { "md5": "3cbeb728ad1f5d6aa62e92b368974811", "sha256": "8497ed749976f9d4d0ddaf797f113d40e643237c50c1889263366cfd56b4c82c" }, "downloads": -1, "filename": "pythonping-1.0.0-py3-none-any.whl", "has_sig": false, "md5_digest": "3cbeb728ad1f5d6aa62e92b368974811", "packagetype": "bdist_wheel", "python_version": "py3", "requires_python": null, "size": 9754, "upload_time": "2018-06-23T19:21:05", "url": "https://files.pythonhosted.org/packages/b7/3e/317942407a02ea187bff2aea6543fe43a464f9d00fb9ffeb51bc082ac0ef/pythonping-1.0.0-py3-none-any.whl" }, { "comment_text": "", "digests": { "md5": "27f51a5cabe761d9dc9eeba3820cfc8c", "sha256": "675f6289af6f770437cf9b1dd03cc0942b34c7db84c41c9f0a218a6b411ef826" }, "downloads": -1, "filename": "pythonping-1.0.0.tar.gz", "has_sig": false, "md5_digest": "27f51a5cabe761d9dc9eeba3820cfc8c", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 12108, "upload_time": "2018-06-23T19:21:06", "url": "https://files.pythonhosted.org/packages/45/94/401a91b2bdf6a161ead45eb3638ea776999831055ccf30bcb4d975a40d08/pythonping-1.0.0.tar.gz" } ], "1.0.1": [ { "comment_text": "", "digests": { "md5": "a2b66ab68f04d4b82844c0f64bfea623", "sha256": "38744576cc113d11ef5dcfa3b620cd3ee78a880913375cde803fe30abac39d43" }, "downloads": -1, "filename": "pythonping-1.0.1-py3-none-any.whl", "has_sig": false, "md5_digest": "a2b66ab68f04d4b82844c0f64bfea623", "packagetype": "bdist_wheel", "python_version": "py3", "requires_python": null, "size": 11052, "upload_time": "2018-06-23T19:25:56", "url": "https://files.pythonhosted.org/packages/04/b9/b1e5e082a663287c72e9d356312d9891eb0f30671fdf8aea110828705fd3/pythonping-1.0.1-py3-none-any.whl" }, { "comment_text": "", "digests": { "md5": "22509c628306c325ec77ecd647a0d393", "sha256": "d9fb0b8a9eb7a7eac25917be4c4efb48738f9917ebee388db67d40b8b0a59f29" }, "downloads": -1, "filename": "pythonping-1.0.1.tar.gz", "has_sig": false, "md5_digest": "22509c628306c325ec77ecd647a0d393", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 13436, "upload_time": "2018-06-23T19:25:57", "url": "https://files.pythonhosted.org/packages/01/a8/cfa6df23ec0cca595b06173bd31a9ef373bca645a0ad3f7561835a3abe28/pythonping-1.0.1.tar.gz" } ], "1.0.2": [ { "comment_text": "", "digests": { "md5": "50f47472106bb50e64efc4a627c9f7f0", "sha256": "e51c2781210f4c401af174dd91d0d6883697681a1e1081803fc25b515d7074e3" }, "downloads": -1, "filename": "pythonping-1.0.2.tar.gz", "has_sig": false, "md5_digest": "50f47472106bb50e64efc4a627c9f7f0", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 13462, "upload_time": "2018-09-08T14:26:30", "url": "https://files.pythonhosted.org/packages/07/b5/f2e2810079725a1eb356d35a139de459f245ad8ae8f5616ecef1d2842d4d/pythonping-1.0.2.tar.gz" } ], "1.0.3": [ { "comment_text": "", "digests": { "md5": "c0f7352bfef9df655da59f1dc0856657", "sha256": "803d7cc0d27303a693a3cb7e6a0c8fdfda9e03129b07fc9bdaaf43b988a57a43" }, "downloads": -1, "filename": "pythonping-1.0.3.tar.gz", "has_sig": false, "md5_digest": "c0f7352bfef9df655da59f1dc0856657", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 13466, "upload_time": "2019-02-24T08:44:07", "url": "https://files.pythonhosted.org/packages/31/98/335f17e370fee1bd63ea1b5497b45f43b1cad309113444063d4afe11002c/pythonping-1.0.3.tar.gz" } ], "1.0.4": [ { "comment_text": "", "digests": { "md5": "c31e30a028ddd0adf5537d22387c5600", "sha256": "2f28c6816f4a2907f9264fe87b8c55a9a78bab40e817315c0c609f1621c6bb00" }, "downloads": -1, "filename": "pythonping-1.0.4.tar.gz", "has_sig": false, "md5_digest": "c31e30a028ddd0adf5537d22387c5600", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 13525, "upload_time": "2019-06-20T19:20:40", "url": "https://files.pythonhosted.org/packages/32/bf/4ca98f89f08bba0ec563509d31d8917e430a88a42590843b911f97f25dab/pythonping-1.0.4.tar.gz" } ], "1.0.5": [ { "comment_text": "", "digests": { "md5": "b2c44e7f3f276170f3a0074c23241445", "sha256": "3740a499a4706b273f9d50ce44a187c0857ce69adb27f0e72e593a7c2bc05d3a" }, "downloads": -1, "filename": "pythonping-1.0.5.tar.gz", "has_sig": false, "md5_digest": "b2c44e7f3f276170f3a0074c23241445", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 14201, "upload_time": "2019-09-01T15:42:45", "url": "https://files.pythonhosted.org/packages/d0/09/45a87cb4590ece11c8f9d9c05b8e05de33fc0377c270738e736f865d0f7c/pythonping-1.0.5.tar.gz" } ] }, "urls": [ { "comment_text": "", "digests": { "md5": "b2c44e7f3f276170f3a0074c23241445", "sha256": "3740a499a4706b273f9d50ce44a187c0857ce69adb27f0e72e593a7c2bc05d3a" }, "downloads": -1, "filename": "pythonping-1.0.5.tar.gz", "has_sig": false, "md5_digest": "b2c44e7f3f276170f3a0074c23241445", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 14201, "upload_time": "2019-09-01T15:42:45", "url": "https://files.pythonhosted.org/packages/d0/09/45a87cb4590ece11c8f9d9c05b8e05de33fc0377c270738e736f865d0f7c/pythonping-1.0.5.tar.gz" } ] }