1 diff --git i/pysimplesoap/c14n.py w/pysimplesoap/c14n.py
2 index 5749e49..297592e 100644
3 --- i/pysimplesoap/c14n.py
4 +++ w/pysimplesoap/c14n.py
5 @@ -55,11 +55,8 @@ except:
7 BASE = "http://www.w3.org/2000/xmlns/"
8 XML = "http://www.w3.org/XML/1998/namespace"
11 - StringIO = cStringIO
15 +from io import StringIO
17 _attrs = lambda E: (E.attributes and E.attributes.values()) or []
18 _children = lambda E: E.childNodes or []
19 diff --git i/pysimplesoap/xmlsec.py w/pysimplesoap/xmlsec.py
20 index 2f96df7..053149f 100644
21 --- i/pysimplesoap/xmlsec.py
22 +++ w/pysimplesoap/xmlsec.py
23 @@ -15,7 +15,7 @@ from __future__ import print_function
27 -from cStringIO import StringIO
28 +from io import StringIO
29 from M2Crypto import BIO, EVP, RSA, X509, m2
31 # if lxml is not installed, use c14n.py native implementation