[jitsi-dev] Updates to the Provisioning Plugin


#1

Moin

I made some updates to the provisioning plugin:

- The downloaded provisioning data is no longer written to a file. It is now processed in-memory. The usage of a file is dangerous as it possibly contains unencrypted account passwords.
- Endless http-redirections are detected and stopped after 20 iterations
- Setting a property to the value ${provisioningpw} causes the provisioning password to be inserted instead. This is useful if an account password is the same as the one being used for provisioning. The server doesn't need to reply with a cleartext password in this case.

Regards,
Ingo

PS: This doesn't yet solve the starvation problem mentioned here http://java.net/projects/jitsi/lists/dev/archive/2011-02/message/54

ProvisioningExtension.patch (5.75 KB)


#2

Hallo Ingo,

I made some updates to the provisioning plugin:
- The downloaded provisioning data is no longer written to a file. It is

While you're at the provisioning and its interface: A couple of weeks/months ago I made a proposal on provisioning:
- In the first screen, that appears when you start Jitsi the first time - put a field to offer to enter the provisioning address. That would make it easier to tell someone to install Jitsi and then simply enter a URL to autoconfigure it.
- Give it a name which explains, what it actually means.

I didn't follow that point further. Perhaps it's a good opportunity to pick it up again..

Grüße aus Berlin :slight_smile:
Conrad


#3

Hey Conrad

- In the first screen, that appears when you start Jitsi the first time -
put a field to offer to enter the provisioning address. That would make it
easier to tell someone to install Jitsi and then simply enter a URL to
autoconfigure it.

I talked about this with Emil off-list: The problem is apparently that provisioning is a "hack". Once the Popup opens where you can enable all sorts of accounts, all of Jitsis services (Account Manager, Protocols, Plugins, etc.) are already loaded. Simply storing the data downloaded from the provisioning URL (or DHCP or mDNS) in the config file won't help, as it is only read during Jitsis startup. While there is a method to re-read the config, some plugins might store the read properties internally and know nothing about the re-read.

The only more or less simple way to create a "provisioning quickstart entry" would be to restart the whole application after the provisioning data is saved to disk.

- Give it a name which explains, what it actually means.

Well that's not up to me... I'm not a committer on Jitsi, I only adapt the application to my needs and try to give the commonly useful stuff back to public.

I didn't follow that point further. Perhaps it's a good opportunity to
pick it up again..

Sure. Emil told me that provisioning is rarely used, so I guess it's not really a priority.

Gruess us Brugg,
Ingo


#4

Hi Conrad, Ingo,

As a first improvement on the subject I've added a link "Use online provisioning" to the first screen (that appears when you start Jitsi for the first time). When clicked it opens the configuration window on the provisioning form.

Thanks for the suggestions!
Yana

···

On Feb 12, 2011, at 11:58 AM, Conrad Beckert wrote:

Hallo Ingo,

I made some updates to the provisioning plugin:
- The downloaded provisioning data is no longer written to a file. It is

While you're at the provisioning and its interface: A couple of weeks/months ago I made a proposal on provisioning:
- In the first screen, that appears when you start Jitsi the first time - put a field to offer to enter the provisioning address. That would make it easier to tell someone to install Jitsi and then simply enter a URL to autoconfigure it.
- Give it a name which explains, what it actually means.

I didn't follow that point further. Perhaps it's a good opportunity to pick it up again..

Grüße aus Berlin :slight_smile:
Conrad


#5

The only more or less simple way to create a "provisioning quickstart
entry" would be to restart the whole application after the provisioning data is
saved to disk.

That would be tolerable wouldn't it. It would be possible to do that automatically?

The idea is to give Jitsi into the hands of non-techies. And it has to be done only once when installing.

I have had lengthy conversations with the colombian part of my family on how to configure Linphone. In their mindset it's completely obvious: Why use something else only for us, if Skype is sooooooo easy to set up. To compete - Jitsi should at least allow me - as the techie - to control the other end. And provisioning is a really cool tool to do so.

Also in my second use case: to get clients on the net to do presentations / trainings via desktop sharing. I don't want do discuss settings with them.

> - Give it a name which explains, what it actually means.

Well that's not up to me... I'm not a committer on Jitsi, I only adapt the
application to my needs and try to give the commonly useful stuff back to
public.

Perhaps someone else on the list has an idea.

Sure. Emil told me that provisioning is rarely used, so I guess it's not
really a priority.

Of course not. It might be the case because noone knows what it is good for and also because all the UI elements are carefully hidden :slight_smile: But it might be a feature to bring Jitsi ahead. I might write an article about it - but as provisioning is now - it's hard to tell a non-techie how to use it.

Grüße
Conrad


#6

Hi Yana,

great! Thank you for your consideration! I'll have an extensive test at the weekend.

Greetings
Conrad

-------- Original-Nachricht --------

···

Datum: Thu, 24 Feb 2011 23:28:05 +0100
Von: Yana Stamcheva <yana@sip-communicator.org>
An: dev@jitsi.java.net
Betreff: [jitsi-dev] Re: Updates to the Provisioning Plugin

Hi Conrad, Ingo,

As a first improvement on the subject I've added a link "Use online
provisioning" to the first screen (that appears when you start Jitsi for the
first time). When clicked it opens the configuration window on the provisioning
form.

Thanks for the suggestions!
Yana

On Feb 12, 2011, at 11:58 AM, Conrad Beckert wrote:

> Hallo Ingo,
>
>> I made some updates to the provisioning plugin:
>> - The downloaded provisioning data is no longer written to a file. It
is
> While you're at the provisioning and its interface: A couple of
weeks/months ago I made a proposal on provisioning:
> - In the first screen, that appears when you start Jitsi the first time
- put a field to offer to enter the provisioning address. That would make
it easier to tell someone to install Jitsi and then simply enter a URL to
autoconfigure it.
> - Give it a name which explains, what it actually means.
>
> I didn't follow that point further. Perhaps it's a good opportunity to
pick it up again..
>
> Grüße aus Berlin :slight_smile:
> Conrad


#7

The only more or less simple way to create a "provisioning quickstart
entry" would be to restart the whole application after the provisioning
data is saved to disk.

That would be tolerable wouldn't it. It would be possible to do that
automatically?

Probably, but I don't know how. I managed to shutdown Jitsi with a System.exit() but I have no idea how to restart it without a helper application. Maybe Felix (the underlying OSGi Framework) would have a way to do that...

The idea is to give Jitsi into the hands of non-techies. And it has to be
done only once when installing.
[snip]

We deploy Jitsi via WebStart to our end users. Maybe that would be an option for you too?
Or if you don't fear writing some lines of Java and build your own Setups, you could pre-fill the provisioning properties like this:

    public static void main(String[] args) throws Exception
    {
        // prepare the provisioning config
        SIPCommunicator.setScHomeDir(System.getProperty("os.name"));

        File configPath =
            new File(System.getProperty(PNAME_SC_HOME_DIR_LOCATION),
                System.getProperty(PNAME_SC_HOME_DIR_NAME));
        configPath.mkdir();
        File configFile = new File(configPath, "sip-communicator.properties");

        Properties p = new Properties();
        if (configFile.exists())
        {
            p.load(new FileInputStream(configFile));
        }

        // enforce the provisioning properties
        p.put("net.java.sip.communicator.plugin.provisioning.METHOD", "Manual");
        p.put("net.java.sip.communicator.plugin.provisioning.URL", "https://yourscript?username&password");
        p.store(new FileOutputStream(configFile), "");

        // launch the original app
        SIPCommunicator.main(args);
    }

Or copy a template sip-communicator.properties from a setup.

- Give it a name which explains, what it actually means.

Well that's not up to me... I'm not a committer on Jitsi, I only adapt
the application to my needs and try to give the commonly useful stuff
back to public.

Perhaps someone else on the list has an idea.

Automatic Profile Download?
Provisioning isn't that bad as it is a single word and actually does what it says.

Sure. Emil told me that provisioning is rarely used, so I guess it's not
really a priority.

Of course not. It might be the case because noone knows what it is good
for and also because all the UI elements are carefully hidden :slight_smile: But it
might be a feature to bring Jitsi ahead. I might write an article about
it - but as provisioning is now - it's hard to tell a non-techie how to
use it.

I guess a non-techie doesn't have a server to provide a profile at all...

Do you have an idea how the enhanced quickstart should look like (maybe create a modified screenshot)? Providing all available options like in the advanced config panel would probably be confusing.

Gruess,
Ingo