libyal / libpff

Library and tools to access the Personal Folder File (PFF) and the Offline Folder File (OFF) format
GNU Lesser General Public License v3.0
289 stars 74 forks source link

ImportError: pypff.so: undefined symbol: libpff_record_set_get_entry_by_index #5

Closed jasonblanks closed 10 years ago

jasonblanks commented 10 years ago

Hey Joachim, hope all is well.

I decided to convert all my scripts using redemption to libpff for PST's. I compile fine using the compile guide and created the debs without issue, I have installed the debs per the guide, all went well.

Testing with a simple: import pypff pypff.get_version()

Produces: /usr/bin/python2.7 /home/me/PycharmProjects/count_libpff/main.py Traceback (most recent call last): File "/home/me/PycharmProjects/count_libpff/main.py", line 1, in import pypff ImportError: /usr/lib/python2.7/dist-packages/pypff.so: undefined symbol: libpff_record_set_get_entry_by_index

Process finished with exit code 1

Any quick solution? See you at osdfcon, looking forward to the plaso class.

jasonblanks commented 10 years ago

For reference, pulled from git master: libpff_20141012-1_amd64.deb libpff-python_20141012-1_amd64.deb

joachimmetz commented 10 years ago

So the bindings are still work in progress see issue 2.

Not sure libpff_record_set_get_entry_by_index appears to be exported in the code what does the following command give you: ldd /usr/lib/python2.7/dist-packages/pypff.so

objdump -R /usr/lib64/libpff.so.1 | grep libpff_record_set_get_entry_by_index

Can you check if you have multiple installations of libpff.so e.g. in /usr/bin and /usr/local/bin

See you at osdfcon,

Won't be there this year, cannot make it time wise.

looking forward to the plaso class.

Is work in progress

jasonblanks commented 10 years ago

jason@Danzig:~/Desktop/Downloads$ ldd /usr/lib/python2.7/dist-packages/pypff.so linux-vdso.so.1 => (0x00007fffe5bfe000) libpthread.so.0 => /lib/x86_64-linux-gnu/libpthread.so.0 (0x00007fbc4c0db000) libpython2.7.so.1.0 => /usr/lib/x86_64-linux-gnu/libpython2.7.so.1.0 (0x00007fbc4bb74000) libpff.so.1 => /usr/lib/x86_64-linux-gnu/libpff.so.1 (0x00007fbc4b85a000) libc.so.6 => /lib/x86_64-linux-gnu/libc.so.6 (0x00007fbc4b494000) /lib64/ld-linux-x86-64.so.2 (0x00007fbc4c562000) libz.so.1 => /lib/x86_64-linux-gnu/libz.so.1 (0x00007fbc4b27b000) libdl.so.2 => /lib/x86_64-linux-gnu/libdl.so.2 (0x00007fbc4b076000) libutil.so.1 => /lib/x86_64-linux-gnu/libutil.so.1 (0x00007fbc4ae73000) libm.so.6 => /lib/x86_64-linux-gnu/libm.so.6 (0x00007fbc4ab6d000) libbfio.so.1 => /usr/lib/x86_64-linux-gnu/libbfio.so.1 (0x00007fbc4a8ad000)

jason@Danzig:~/Desktop/Downloads$ objdump -R /usr/lib/x86_64-linux-gnu/libpff.so.1 | grep libpff_record_set_get_entry_by_index jason@Danzig:~/Desktop/Downloads$

joachimmetz commented 10 years ago

I'm unable to reproduce this. Can you double check if you have multiple versions of libpff.so on your system.

jasonblanks commented 10 years ago

Looks like I do..... looks like dff installed an old version. I'll try removing dff and dependencies and see what happens.

jason@Danzig:~/Desktop/Downloads$ sudo find / -name libpff.so /usr/lib/libpff.so /home/jason/Desktop/Downloads/libpff-master/debian/tmp/usr/lib/libpff.so /home/jason/Desktop/Downloads/libpff-master/debian/libpff-dev/usr/lib/libpff.so /home/jason/Desktop/Downloads/libpff-master/libpff/.libs/libpff.so

jason@Danzig:~/Desktop/Downloads$

jason@Danzig:~/Desktop/Downloads$ dpkg --get-selections | grep pff libpff install libpff-dbg install libpff-dev install libpff-python install libpff-python-dbg install libpff-tools install

libpff1 install

jason@Danzig:~/Desktop/Downloads$ dpkg -l | grep pff ii libpff 20141012-1 amd64 Library to access the Personal Folder File (PFF) and the Offline Folder File (OFF) format. PFF is used in PAB (Personal Address Book), PST (Personal Storage Table) and OST (Offline Storage Table) files. ii libpff-dbg 20141012-1 amd64 Debugging symbols for libpff ii libpff-dev 20141012-1 amd64 Header files and libraries for developing applications for libpff ii libpff-python 20141012-1 amd64 Python bindings for libpff ii libpff-python-dbg 20141012-1 amd64 Debugging symbols for libpff-python ii libpff-tools 20141012-1 amd64 Several tools for reading Personal Folder Files (OST, PAB and PST)

ii libpff1 20120802-1ubuntu1 amd64 library to access various ms outlook files formats.

jason@Danzig:~/Desktop/Downloads$ apt-cache rdepends libpff1 libpff1 Reverse Depends: libpff1:i386 pff-tools libpff-dev libpff-dbg dff jason@Danzig:~/Desktop/Downloads$ apt-cache rdepends libpff1:i386 libpff1:i386 Reverse Depends: pff-tools:i386 libpff1 libpff-dev:i386 libpff-dbg:i386 dff:i386 jason@Danzig:~/Desktop/Downloads$ apt-cache rdepends dff:i386 dff:i386 Reverse Depends:

dff

jasonblanks commented 10 years ago

Looks good now, sorry for the false alarm.

/usr/bin/python2.7 /home/jason/PycharmProjects/count_libpff/main.py 20141012

Process finished with exit code 0


joachimmetz commented 10 years ago

Good to hear, thx for the update. Closing issue.