Skip to content
This repository was archived by the owner on Oct 29, 2024. It is now read-only.
This repository was archived by the owner on Oct 29, 2024. It is now read-only.

Some data will cause InfluxDBClientError #365

Closed
@virusdefender

Description

@virusdefender
# coding=utf-8
from influxdb import InfluxDBClient

client = InfluxDBClient("influxdb.in.example.com", 8086, "admin", "admin", "attack_log")

client.write_points([{u'fields': {u'node': u'safeline-test', u'extra': u'', u'referer': u'http://www.0411fc.org/html/about/include/dialog/select_templets_post.php?adminDirHand=\\"/></script><script>alert(1);</script>', u'urlpath': u'/html/about/include/dialog/select_templets_post.php?adminDirHand=%22/%3E%3C/script%3E%3Cscript%3Ealert(1);%3C/script%3E', u'module': u'm_xss', u'decode_path': u'url_parse', u'attack_type': u'xss', u'risk_level': u'high', u'event_id': u'', u'src_ip': u'192.168.30.111', u'location': u'urlpath', u'method': u'GET', u'province': u'\u5176\u4ed6', u'reason': u'', u'host': u'safeline-test.in.***.com', u'action': u'deny', u'useragent': u'Mozilla/4.0 (compatible; MSIE 7.0; Windows NT 5.1; .NET CLR 1.1.4322)'}, u'tags': {u'log_id': 12345}, u'time': '2016-05-07T10:26:10.721946', u'measurement': u'request_log'}])

response

{"error":"unable to parse 'request_log,log_id=12345 action=\"deny\",attack_type=\"xss\",decode_path=\"url_parse\",host=\"safeline-test.in.***.com\",location=\"urlpath\",method=\"GET\",module=\"m_xss\",node=\"safeline-test\",province=\"其他\",referer=\"http://www.0411fc.org/html/about/include/dialog/select_templets_post.php?adminDirHand=\\\\\"/\u003e\u003c/script\u003e\u003cscript\u003ealert(1);\u003c/script\u003e\",risk_level=\"high\",src_ip=\"192.168.30.111\",urlpath=\"/html/about/include/dialog/select_templets_post.php?adminDirHand=%22/%3E%3C/script%3E%3Cscript%3Ealert(1);%3C/script%3E\",useragent=\"Mozilla/4.0 (compatible; MSIE 7.0; Windows NT 5.1; .NET CLR 1.1.4322)\" 1462616770721946112': invalid boolean"}
  • Python 2.7.11
  • InfluxDB-Python 3.0.0
  • InfluxDB 0.13.0

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions