Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Python 2.6 support for OrderedDict #42

Closed
GoogleCodeExporter opened this issue Mar 27, 2015 · 2 comments
Closed

Python 2.6 support for OrderedDict #42

GoogleCodeExporter opened this issue Mar 27, 2015 · 2 comments

Comments

@GoogleCodeExporter
Copy link

What steps will reproduce the problem?
1. Try to run wmiexec.py w/ Python 2.6 using ordereddict installed via pip on 
Debian 7 x64

# pip install ordereddict
Downloading/unpacking ordereddict
  Downloading ordereddict-1.1.tar.gz
  Running setup.py egg_info for package ordereddict
Installing collected packages: ordereddict
  Running setup.py install for ordereddict
Successfully installed ordereddict
Cleaning up...

What is the expected output? What do you see instead?

Expected:

Impacket v0.9.12-dev - Copyright 2002-2014 Core Security Technologies

Password:
SMBv2.1 dialect used
[!] Launching semi-interactive shell - Careful what you execute
C:\>

Saw:

./wmiexec.py administrator@172.16.102.216
Traceback (most recent call last):
  File "./wmiexec.py", line 34, in <module>
    from impacket.dcerpc.v5.dcom import wmi
  File "/usr/local/lib/python2.6/dist-packages/impacket/dcerpc/v5/dcom/wmi.py", line 51, in <module>
    from ordereddict.ordereddict import OrderedDict
ImportError: No module named ordereddict


What version of the product are you using? On what operating system?

Trunk

Please provide any additional information below.

Fix was to change:
   python2.6/dist-packages/impacket/dcerpc/v5/dcom/wmi.py

Line: 51
from:
    from ordereddict.ordereddict import OrderedDict
to:
    from ordereddict import OrderedDict


Original issue reported on code.google.com by jd.mu...@gmail.com on 16 Apr 2014 at 7:54

@GoogleCodeExporter
Copy link
Author

Thanks for the report.. 

I need to leave ordereddict.ordereddict for Impact.. but I will add the import 
you mentioned as another try/except clause.. I don't like it but for the 
moment, until I figured it out, solve the problem. 

I thought, under standalone python OrderedDict was located under collections.

thanks again!
beto

Original comment by bet...@gmail.com on 16 Apr 2014 at 8:22

  • Changed state: Accepted
  • Added labels: ****
  • Removed labels: ****

@GoogleCodeExporter
Copy link
Author

Fixed in https://code.google.com/p/impacket/source/detail?r=1217

Let me know if it works.

thanks dude!
bto

Original comment by bet...@gmail.com on 16 Apr 2014 at 8:33

  • Changed state: Fixed
  • Added labels: ****
  • Removed labels: ****

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

1 participant