Comment 1 for bug 1212205

Revision history for this message
Raphaƫl Badin (rvb) wrote :

My first intention was to simply remove the get_by_name() API operation from the anonymous handler. This is what I've done in https://code.launchpad.net/~rvb/maas/fix-get-file-by-name/+merge/187754 and the package I created from it worked fine with juju-core because juju-core uses either authenticated calls or get_file_by_key() to access the files it needs.

Sadly, this is not the case with (py)juju which really needs the anonymous get_by_name() API operation. Note that it needs it to get from the MAAS server files related to charms and which contain a random element (the file names are something like 'mysql-charm-sdfkj56lkjsdflkj4td'). The random element is probably there to mitigate the security risk.

This is rather problematic because the same code has to accommodate both juju-core and (py)juju. We could land my branch above if we choose to abandon pyjuju compatibility.