No ssl on drobo

I installed SabNzbd on my Drobo. I installed first the python package from droboports that I thought came with openSSL. But when I go to my sabnzbd configuration it says that SSL encryption is not available because is not installed on the device. How canb I make openssl work? Is there an individual package for the Drobo?
Thans for your answers in advance

That is very surprising, since python is compiled with openssl linked statically. In other words, it is part of the python executable. Or at least it should, since I don’t remember seeing any compilation errors. Can you provide some more information about the error messages?

barbecuy may have mispoke, it needs pyopenssl, which maybe needs to be crosscompiled? im flying blind here (but im using your tutorial @ricardo to do my first attempt at handling this one myself) but please stop me if im heading down a useless path.

easy_install totally failed on pyopenssl, so i assume this is the only way to go.

Ok, now I see what you guys are trying to do. First, let me enumerate the facts:
[list=1]
[]Python for the DroboFS from DroboPorts does contain openssl, but it is statically linked, i.e., the functionality is there, but it is included in the executable instead of in a separate library.
[
]pyOpenSSL requires OpenSSL as a library
[]The DroboFS does ship with OpenSSL as a library. In fact, if you SSH into it, and look under /lib, you’ll find libssl.so.0.9.8
[
]Unfortunately, the FS does not ship with the tools necessary to compile software. It also lacks the necessary header files to enable compilation.
[/list]
From what I could see in the source code of pyOpenSSL, it does require compilation (i.e. it includes C source code).

The good news is that (theoretically) it should be possible to cross-compile this, since it should be just a matter of telling python on the cross-compiling VM to use the cross-compiler. The bad news is that I have no idea if this is actually possible.

In any case, this should work like this:
[list=1]
[]Get a cross compiling VM as indicated here: http://www.droboports.com/setting-up-a-vm
[
]Cross compile openssl as indicated here: http://www.droboports.com/lib-repository/openssl (I strongly suggest using the latest version - 1.0.1)
[]Install python on the VM using apt-get
[
]Use the local python to compile pyOpenSSL, but using the cross-compiler instead of the local compiler.
[*]Copy the result of the compilation to the FS.
[/list]
Steps 1-3 should be pretty straightforward. Step 4 is the tricky one.

A quick google search for “cross compile python egg” got me this: http://whatschrisdoing.com/blog/2009/10/16/cross-compiling-python-extensions/ It does seem to indicate that it is possible.

Good luck!

ricardo if you discover anything let me know. i was able to build pyopenssl, but it didnt seem to respect the cflags at all… so i have it for intel… -_-

nevermind, i definitely am talking out of my ass. i have no clue how to cross compile using setuptools and disutilscross, but im playing around.

Two things:

  1. I made a new version of python. You can find it here: http://www.droboports.com/app-repository/python-2-7-2

  2. I also tried to cross-compile pyOpenSSL, and I think I got it right. If you feel like beta-testing for me, you can go to your FS and run:

/mnt/DroboFS/Shares/DroboApps/python2/bin/easy_install http://commondatastorage.googleapis.com/drobofs/pyOpenSSL-0.13-py2.7-linux-i686.egg

Just make sure you installed easy_install as indicated in the DroboPorts page.

This is what should happen:

Downloading http://commondatastorage.googleapis.com/drobofs/pyOpenSSL-0.13-py2.7-linux-i686.egg
Processing pyOpenSSL-0.13-py2.7-linux-i686.egg
removing '/mnt/DroboFS/Shares/DroboApps/python2/lib/python2.7/site-packages/pyOpenSSL-0.13-py2.7-linux-i686.egg' (and everything under it)
creating /mnt/DroboFS/Shares/DroboApps/python2/lib/python2.7/site-packages/pyOpenSSL-0.13-py2.7-linux-i686.egg
Extracting pyOpenSSL-0.13-py2.7-linux-i686.egg to /mnt/DroboFS/Shares/DroboApps/python2/lib/python2.7/site-packages
pyOpenSSL 0.13 is already the active version in easy-install.pth

Installed /mnt/DroboFS/Shares/DroboApps/python2/lib/python2.7/site-packages/pyOpenSSL-0.13-py2.7-linux-i686.egg
Processing dependencies for pyOpenSSL==0.13
Searching for pyOpenSSL==0.13
Reading http://pypi.python.org/simple/pyOpenSSL/
Reading http://pyopenssl.sourceforge.net/
Reading http://launchpad.net/pyopenssl
Best match: pyOpenSSL 0.13
Downloading http://pypi.python.org/packages/source/p/pyOpenSSL/pyOpenSSL-0.13.tar.gz#md5=767bca18a71178ca353dff9e10941929
Processing pyOpenSSL-0.13.tar.gz
Running pyOpenSSL-0.13/setup.py -q bdist_egg --dist-dir /tmp/easy_install-P4zj70/pyOpenSSL-0.13/egg-dist-tmp-tyCgby
warning: no previously-included files matching '*.pyc' found anywhere in distribution
unable to execute /usr/local/arm-2007q1/bin/arm-none-linux-gnueabi-gcc: No such file or directory
error: Setup script exited with error: command '/usr/local/arm-2007q1/bin/arm-none-linux-gnueabi-gcc' failed with exit status 1

Don’t pay attention to the error messages. You can check that the module was installed by looking inside /mnt/DroboFS/Shares/DroboApps/python2/lib/python2.7/site-packages/pyOpenSSL-0.13-py2.7-linux-i686.egg/ :

-rw-r--r--    1 root     root          273 Mar 23 18:39 SSL.py
-rw-r--r--    1 root     root          677 Mar 23 18:39 SSL.pyc
-rwxr-xr-x    1 root     root      1952662 Mar 23 18:39 SSL.so
-rw-r--r--    1 root     root          965 Mar 23 18:39 __init__.py
-rw-r--r--    1 root     root         1018 Mar 23 18:39 __init__.pyc
-rw-r--r--    1 root     root          276 Mar 23 18:39 crypto.py
-rw-r--r--    1 root     root          686 Mar 23 18:39 crypto.pyc
-rwxr-xr-x    1 root     root      1894264 Mar 23 18:39 crypto.so
-rw-r--r--    1 root     root          274 Mar 23 18:39 rand.py
-rw-r--r--    1 root     root          680 Mar 23 18:39 rand.pyc
-rwxr-xr-x    1 root     root      1262444 Mar 23 18:39 rand.so
drwxr-xr-x    2 root     root         4096 Mar 23 18:39 test
-rw-r--r--    1 root     root         1010 Mar 23 18:39 tsafe.py
-rw-r--r--    1 root     root         1968 Mar 23 18:39 tsafe.pyc
-rw-r--r--    1 root     root          176 Mar 23 18:39 version.py
-rw-r--r--    1 root     root          320 Mar 23 18:39 version.pyc

Let me know how it works for you. :slight_smile:

I’m trying this out. It installed exactly how you said it would with easy install. I started SAB and I see 2012-03-23 15:14:25,695::INFO::[SABnzbd:490] pyOpenSSL... found (True)

It hangs at URLGrabber Starting up

@ndininno, i think you’re up and running. Did you try to navigate to your IP address port :8085?

@ricardo you are a SAINT. THANK YOU SO MUCH!!!

Now… however you did that, can it also be used to cross compile pysqlite?

If you can post instructions on what flags you set to cross compile, I could totally get there based on your previous whatischrisdoing walkthrough.

Well i was starting it up with the command

python SABnzbd.py -s localhost:7222

I’m unable to open that on port 7222 from my browser. I assumed if SAB was fully finishing its startup i would be brought back to # but after what I mentioned before it just sits there forever.

nope, when sab is running (not in daemon mode), it stays open and logs to she console. when runas a daemon using a service.sh script it will behave more akin to other drobo apps. id recommend googling sabnzbd, drobofs and servicesh.

youll find what you’re looking for.

Yes I’ve seen that blog you’re referring to about the service.sh but it still doesn’t explain why I can’t browse to the app and configure. I can’t even see where my ini file is to edit it.

you shouldnt need to edit any ini, and you shouldnt need to pass in any arguments… python SABnzbd.py should be all you need and it should run on [drobo-fs.local/ip address]:8085

I’m not able to get to it, not really sure what I’m doing wrong at this point and I don’t want to derail this post any further so I’m starting a new one.

Please, please… I prefer the moniker “miracle worker”. :wink:

Jokes aside, I’ll try to post a howto for python extensions as soon as I can.

cool man, thanks again, my couchpotato eagerly awaits it.

ndininno (or ricardo/drewcovi),

I am stuck in the process at the same spot as you were with this post. That is, I’ve run SAB using python, and I cannot access the web interface at the 8085 port of my drobo’s IP. I see in a different thread that you got past this, but I can’t find how on the forums. Can you shed some light on how you were able to access SAB’s web interface?

Thanks, any help is appreciated, as this is one of the last major pieces to the puzzle.

-Devon