{"action":"closed","issue":{"url":"https://api.github.com/repos/DSIE/crits/issues/1","labels_url":"https://api.github.com/repos/DSIE/crits/issues/1/labels{/name}","comments_url":"https://api.github.com/repos/DSIE/crits/issues/1/comments","events_url":"https://api.github.com/repos/DSIE/crits/issues/1/events","html_url":"https://github.com/DSIE/crits/issues/1","id":64531973,"number":1,"title":"TAXII Service - PCAPs File: 'File' object has no attribute 'description'","user":{"login":"packet-rat","id":3220193,"avatar_url":"https://avatars.githubusercontent.com/u/3220193?v=3","gravatar_id":"","url":"https://api.github.com/users/packet-rat","html_url":"https://github.com/packet-rat","followers_url":"https://api.github.com/users/packet-rat/followers","following_url":"https://api.github.com/users/packet-rat/following{/other_user}","gists_url":"https://api.github.com/users/packet-rat/gists{/gist_id}","starred_url":"https://api.github.com/users/packet-rat/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/packet-rat/subscriptions","organizations_url":"https://api.github.com/users/packet-rat/orgs","repos_url":"https://api.github.com/users/packet-rat/repos","events_url":"https://api.github.com/users/packet-rat/events{/privacy}","received_events_url":"https://api.github.com/users/packet-rat/received_events","type":"User","site_admin":false},"labels":[],"state":"closed","locked":false,"assignee":null,"milestone":null,"comments":2,"created_at":"2015-03-26T13:55:17Z","updated_at":"2015-04-01T16:44:29Z","closed_at":"2015-04-01T16:44:29Z","body":"From: https://github.com/crits/crits/pull/427\r\n\r\nbrlogan added a note 6 hours ago\r\nI was seeing a File: Incorrect padding failure message, but only when receiving certain Samples via TAXII Agent. I eventually realized that even the Samples that were making it through without an error had bad data. After some work, I managed to trace this problem to the above line. I didn't dig very deep into the python-stix code, but it appears that STIXPackage.from_xml() does the work of base64 decoding the Sample data. So, when the above line executes, it is trying to decode already decoded data, which causes the error.\r\nChanging data = base64.b64decode(obj.properties.data) to data = obj.properties.data seems to solve the problem.\r\n\r\nmgoffin added a note an hour ago\r\nI wonder if it does the same things for PCAP, RawData, and Certificate binary data...\r\n\r\n@mgoffin:  I wonder if it does the same things for PCAP: Yes\r\n\r\n![voila_capture 2015-03-26_09-31-54_am](https://cloud.githubusercontent.com/assets/3220193/6847216/2a9137e4-d39b-11e4-8a3d-f014ba5054eb.jpg)\r\n\r\n[20150326-134035: Update - It turns out the PCAP at the Source CRITs didn't have a \"Description\".  However, entering a description and resending resulted in the same error.\r\n![voila_capture 2015-03-26_09-42-29_am](https://cloud.githubusercontent.com/assets/3220193/6847370/8602248e-d39c-11e4-9a1f-864d5b15f895.jpg)\r\n"}}