On 07/01/2013 12:32 PM, Simone Orsi wrote:
On 07/01/2013 12:14 PM, Dimitris Moraitis wrote
I'm pretty sure that the exception is thrown at line 76 in xmlrpc.py
because of the following call:
encrypt(str((input['uid'],input['fieldName'],profileId)),
self.master.config['secret'])
Perhaps the secret isn't retrieved correctly for some reason?
yes, that is what I am about to debug.
ok, debugging this gave no clue since is working as expected :S
I catch the values from the log and I tried to do the same operations by
hand:
>>> theinput = {'key':
'F+9E5LZCyjjP89g69wKrKAMKnI4ruHrXVK0S8EqaRmu++MO6cvpLHVb2OcssxxNXNJy7DxT13gSmHvXaUuX1A1SACcplQgeor8W7wAKpxP2aBJPddkPeUo9tmwi5++e9+kQ5305ltLTQuuJYS30+c1TKLmaYXV0unSePD61jKp0IuBMCnAu7dS79Sg71I2jgH8GlFlSANzrfIxBN7kKG7oJKVjqwCazm6EhQ2+HlrbeSgURIqLVM67c90+grXxQgGlwWTWHgI8qkyhpKOhqF7DFflrXTy0q5Xr2VCIzD8QVDyMYijJ6fmhiNf1H0zxJZed7yqM9mAoX6h8cdX2fGpdKO8AEzT+oUZT3evcKk1gK/f2Utk5qbh++tKrCcQqwsHkj784F0wNo3BHFvuP2/bCmR5GhMe+0VvMD7NJRzvGgcRQoiK0IrzeeGiAJGvLVoim1JY9zS8JchOoSvHgX0sTHHKEN8V7gh'}
>>> profileId = 'webm-high'
>>> secret = '1771d99931264d53'
>>> key = decrypt(b64decode(theinput['key']), secret)
>>> key
"{'uid': 'bc9844d71bbf4c51b34a8228b0249649', 'url':
'http://plumi.host/plumi/@@serve_daemon', 'fileName': 'testvideo',
'fieldName': '', 'path':
'http://plumi.host/plumi/Members/webtvadmin/videos/testvideo.mp4',
'type': 'video/mp4'}"
>>> theinput = eval(key, {"__builtins__":None},{})
>>> theinput
{'uid': 'bc9844d71bbf4c51b34a8228b0249649', 'url':
'http://plumi.host/plumi/@@serve_daemon', 'fileName': 'testvideo',
'fieldName': '', 'path':
'http://plumi.host/plumi/Members/webtvadmin/videos/testvideo.mp4',
'type': 'video/mp4'}
>>>
b64encode(encrypt(str((theinput['uid'],theinput['fieldName'],profileId)), secret))
'RC0ULVTS7F+/fhsgoHxhxlRCFj2FFStz1sl1xFdNLMdlnnFJTX5enfC6qoKpZIiXIkD7+lwJ5yuT'
I also make it log the secret from the lazy call:
2013-07-01 13:28:21+0200 [HTTPChannel,5,192.107.92.224] XXXXXXXXXXXX
lazy CALL XXXXXXXXXXXXXXXXXX
2013-07-01 13:28:21+0200 [HTTPChannel,5,192.107.92.224] SECRET:
1771d99931264d53
2013-07-01 13:28:21+0200 [HTTPChannel,5,192.107.92.224] SECRET LEN: 16
2013-07-01 13:28:21+0200 [HTTPChannel,5,192.107.92.224]
XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX
and everything is ok, no padding added.
Nonetheless I get the same error, "|ValueError: IV must be 16 bytes
long" | that I found explained here:
http://tea.cesaroliveira.net/archives/156
I cannot really get what's going wrong :S
On 2013-07-01 13:11, Simone Orsi wrote:
On 07/01/2013 11:51 AM, Dimitris Moraitis wrote:
I think you just need to configure the transcoder secret to be a
string of 16 or 32 bytes.
Actually I was using the default one from basic buildout, that is
32bytes long https://github.com/plumi/plumi.app/blob/master/site.cfg#L67
I tried to cut it down to 16bytes (1771d99931264d53) but I get the
same error :(
Hope that helps,
Dimitris
On 2013-07-01 12:49, Simone Orsi wrote:
Hi,
I'm setup a transcoder instance on a separate machine. The very same
setup on the same plumi machine works.
When a transcode request is triggered the log of the daemon says:
2013-06-28 15:03:36+0200 [HTTPChannel,5,192.107.92.224] Invalid
transcode request: IV must be 16 bytes long
and the request fails. It looks like I cannot place a pdb into the
daemon to see what is passed (it never stops on it).
Can you give any pointer on the problem itself or at least on how to
debug the transcoder daemon?
Thanks in advance,
S.
--
https://unweb.me
--
https://unweb.me
_______________________________________________
Discuss mailing list
[email protected]
http://lists.plumi.org/listinfo/discuss