You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@maven.apache.org by Simone Tripodi <si...@gmail.com> on 2010/08/28 16:22:29 UTC

Decrypting server password

Hi all guys,
a friend of mine and I are developing a maven plugin that needs to
acces to a server credentials specified in the settings.xml; no
problem since the org.apache.maven.settings.Server class exposes
methods to retrieve username/password, the problem comes when
passwords are encrypted using the method described in the
guide-encryption[1].
How can we decrypt the password inside the plugin code? Thanks in advance!
All the best,
Simo

[1] http://maven.apache.org/guides/mini/guide-encryption.html

http://people.apache.org/~simonetripodi/
http://www.99soft.org/

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@maven.apache.org
For additional commands, e-mail: users-help@maven.apache.org


Re: Decrypting server password

Posted by Simone Tripodi <si...@gmail.com>.
Thanks a lot, just noticed the trunk[1] is the right place!!!
thanks again, have a nice day!
Simo

http://svn.codehaus.org/mojo/trunk/mojo/sql-maven-plugin/src/main/java/org/codehaus/mojo/sql/SqlExecMojo.java

http://people.apache.org/~simonetripodi/
http://www.99soft.org/



On Sat, Aug 28, 2010 at 6:10 PM, Dan Tran <da...@gmail.com> wrote:
> see the latest trunk source starting from the pom.xml
>
> -Dan
>
> On Sat, Aug 28, 2010 at 8:04 AM, Simone Tripodi
> <si...@gmail.com> wrote:
>> Hi Dan,
>> it doesn't seem the sql-plugin[1] manages encrypted passwords... am I
>> checking in the wrong place?
>> Thanks in advance,
>> Simo
>>
>> [1] http://svn.codehaus.org/mojo/tags/sql-maven-plugin-1.4/src/main/java/org/codehaus/mojo/sql/SqlExecMojo.java
>>
>> http://people.apache.org/~simonetripodi/
>> http://www.99soft.org/
>>
>>
>>
>> On Sat, Aug 28, 2010 at 4:53 PM, Simone Tripodi
>> <si...@gmail.com> wrote:
>>> Hi Dan,
>>> thanks for the hint, going to read the code!
>>> Simo
>>>
>>> http://people.apache.org/~simonetripodi/
>>> http://www.99soft.org/
>>>
>>>
>>>
>>> On Sat, Aug 28, 2010 at 4:34 PM, Dan Tran <da...@gmail.com> wrote:
>>>> see sql-maven-plugin's implementation
>>>>
>>>> -D
>>>>
>>>> On Sat, Aug 28, 2010 at 7:22 AM, Simone Tripodi
>>>> <si...@gmail.com> wrote:
>>>>> Hi all guys,
>>>>> a friend of mine and I are developing a maven plugin that needs to
>>>>> acces to a server credentials specified in the settings.xml; no
>>>>> problem since the org.apache.maven.settings.Server class exposes
>>>>> methods to retrieve username/password, the problem comes when
>>>>> passwords are encrypted using the method described in the
>>>>> guide-encryption[1].
>>>>> How can we decrypt the password inside the plugin code? Thanks in advance!
>>>>> All the best,
>>>>> Simo
>>>>>
>>>>> [1] http://maven.apache.org/guides/mini/guide-encryption.html
>>>>>
>>>>> http://people.apache.org/~simonetripodi/
>>>>> http://www.99soft.org/
>>>>>
>>>>> ---------------------------------------------------------------------
>>>>> To unsubscribe, e-mail: users-unsubscribe@maven.apache.org
>>>>> For additional commands, e-mail: users-help@maven.apache.org
>>>>>
>>>>>
>>>>
>>>> ---------------------------------------------------------------------
>>>> To unsubscribe, e-mail: users-unsubscribe@maven.apache.org
>>>> For additional commands, e-mail: users-help@maven.apache.org
>>>>
>>>>
>>>
>>
>> ---------------------------------------------------------------------
>> To unsubscribe, e-mail: users-unsubscribe@maven.apache.org
>> For additional commands, e-mail: users-help@maven.apache.org
>>
>>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscribe@maven.apache.org
> For additional commands, e-mail: users-help@maven.apache.org
>
>

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@maven.apache.org
For additional commands, e-mail: users-help@maven.apache.org


Re: Decrypting server password

Posted by Dan Tran <da...@gmail.com>.
see the latest trunk source starting from the pom.xml

-Dan

On Sat, Aug 28, 2010 at 8:04 AM, Simone Tripodi
<si...@gmail.com> wrote:
> Hi Dan,
> it doesn't seem the sql-plugin[1] manages encrypted passwords... am I
> checking in the wrong place?
> Thanks in advance,
> Simo
>
> [1] http://svn.codehaus.org/mojo/tags/sql-maven-plugin-1.4/src/main/java/org/codehaus/mojo/sql/SqlExecMojo.java
>
> http://people.apache.org/~simonetripodi/
> http://www.99soft.org/
>
>
>
> On Sat, Aug 28, 2010 at 4:53 PM, Simone Tripodi
> <si...@gmail.com> wrote:
>> Hi Dan,
>> thanks for the hint, going to read the code!
>> Simo
>>
>> http://people.apache.org/~simonetripodi/
>> http://www.99soft.org/
>>
>>
>>
>> On Sat, Aug 28, 2010 at 4:34 PM, Dan Tran <da...@gmail.com> wrote:
>>> see sql-maven-plugin's implementation
>>>
>>> -D
>>>
>>> On Sat, Aug 28, 2010 at 7:22 AM, Simone Tripodi
>>> <si...@gmail.com> wrote:
>>>> Hi all guys,
>>>> a friend of mine and I are developing a maven plugin that needs to
>>>> acces to a server credentials specified in the settings.xml; no
>>>> problem since the org.apache.maven.settings.Server class exposes
>>>> methods to retrieve username/password, the problem comes when
>>>> passwords are encrypted using the method described in the
>>>> guide-encryption[1].
>>>> How can we decrypt the password inside the plugin code? Thanks in advance!
>>>> All the best,
>>>> Simo
>>>>
>>>> [1] http://maven.apache.org/guides/mini/guide-encryption.html
>>>>
>>>> http://people.apache.org/~simonetripodi/
>>>> http://www.99soft.org/
>>>>
>>>> ---------------------------------------------------------------------
>>>> To unsubscribe, e-mail: users-unsubscribe@maven.apache.org
>>>> For additional commands, e-mail: users-help@maven.apache.org
>>>>
>>>>
>>>
>>> ---------------------------------------------------------------------
>>> To unsubscribe, e-mail: users-unsubscribe@maven.apache.org
>>> For additional commands, e-mail: users-help@maven.apache.org
>>>
>>>
>>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscribe@maven.apache.org
> For additional commands, e-mail: users-help@maven.apache.org
>
>

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@maven.apache.org
For additional commands, e-mail: users-help@maven.apache.org


Re: Decrypting server password

Posted by Simone Tripodi <si...@gmail.com>.
Hi Dan,
it doesn't seem the sql-plugin[1] manages encrypted passwords... am I
checking in the wrong place?
Thanks in advance,
Simo

[1] http://svn.codehaus.org/mojo/tags/sql-maven-plugin-1.4/src/main/java/org/codehaus/mojo/sql/SqlExecMojo.java

http://people.apache.org/~simonetripodi/
http://www.99soft.org/



On Sat, Aug 28, 2010 at 4:53 PM, Simone Tripodi
<si...@gmail.com> wrote:
> Hi Dan,
> thanks for the hint, going to read the code!
> Simo
>
> http://people.apache.org/~simonetripodi/
> http://www.99soft.org/
>
>
>
> On Sat, Aug 28, 2010 at 4:34 PM, Dan Tran <da...@gmail.com> wrote:
>> see sql-maven-plugin's implementation
>>
>> -D
>>
>> On Sat, Aug 28, 2010 at 7:22 AM, Simone Tripodi
>> <si...@gmail.com> wrote:
>>> Hi all guys,
>>> a friend of mine and I are developing a maven plugin that needs to
>>> acces to a server credentials specified in the settings.xml; no
>>> problem since the org.apache.maven.settings.Server class exposes
>>> methods to retrieve username/password, the problem comes when
>>> passwords are encrypted using the method described in the
>>> guide-encryption[1].
>>> How can we decrypt the password inside the plugin code? Thanks in advance!
>>> All the best,
>>> Simo
>>>
>>> [1] http://maven.apache.org/guides/mini/guide-encryption.html
>>>
>>> http://people.apache.org/~simonetripodi/
>>> http://www.99soft.org/
>>>
>>> ---------------------------------------------------------------------
>>> To unsubscribe, e-mail: users-unsubscribe@maven.apache.org
>>> For additional commands, e-mail: users-help@maven.apache.org
>>>
>>>
>>
>> ---------------------------------------------------------------------
>> To unsubscribe, e-mail: users-unsubscribe@maven.apache.org
>> For additional commands, e-mail: users-help@maven.apache.org
>>
>>
>

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@maven.apache.org
For additional commands, e-mail: users-help@maven.apache.org


Re: Decrypting server password

Posted by Simone Tripodi <si...@gmail.com>.
Hi Dan,
thanks for the hint, going to read the code!
Simo

http://people.apache.org/~simonetripodi/
http://www.99soft.org/



On Sat, Aug 28, 2010 at 4:34 PM, Dan Tran <da...@gmail.com> wrote:
> see sql-maven-plugin's implementation
>
> -D
>
> On Sat, Aug 28, 2010 at 7:22 AM, Simone Tripodi
> <si...@gmail.com> wrote:
>> Hi all guys,
>> a friend of mine and I are developing a maven plugin that needs to
>> acces to a server credentials specified in the settings.xml; no
>> problem since the org.apache.maven.settings.Server class exposes
>> methods to retrieve username/password, the problem comes when
>> passwords are encrypted using the method described in the
>> guide-encryption[1].
>> How can we decrypt the password inside the plugin code? Thanks in advance!
>> All the best,
>> Simo
>>
>> [1] http://maven.apache.org/guides/mini/guide-encryption.html
>>
>> http://people.apache.org/~simonetripodi/
>> http://www.99soft.org/
>>
>> ---------------------------------------------------------------------
>> To unsubscribe, e-mail: users-unsubscribe@maven.apache.org
>> For additional commands, e-mail: users-help@maven.apache.org
>>
>>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscribe@maven.apache.org
> For additional commands, e-mail: users-help@maven.apache.org
>
>

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@maven.apache.org
For additional commands, e-mail: users-help@maven.apache.org


Re: Decrypting server password

Posted by Dan Tran <da...@gmail.com>.
see sql-maven-plugin's implementation

-D

On Sat, Aug 28, 2010 at 7:22 AM, Simone Tripodi
<si...@gmail.com> wrote:
> Hi all guys,
> a friend of mine and I are developing a maven plugin that needs to
> acces to a server credentials specified in the settings.xml; no
> problem since the org.apache.maven.settings.Server class exposes
> methods to retrieve username/password, the problem comes when
> passwords are encrypted using the method described in the
> guide-encryption[1].
> How can we decrypt the password inside the plugin code? Thanks in advance!
> All the best,
> Simo
>
> [1] http://maven.apache.org/guides/mini/guide-encryption.html
>
> http://people.apache.org/~simonetripodi/
> http://www.99soft.org/
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscribe@maven.apache.org
> For additional commands, e-mail: users-help@maven.apache.org
>
>

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@maven.apache.org
For additional commands, e-mail: users-help@maven.apache.org


Re: Decrypting server password

Posted by Simone Tripodi <si...@gmail.com>.
Hi Tony,
thanks!!! Even if I already solved, I'll take look as well at your
suggestions to improve the performances!!!
Thanks a lot!
Simo

http://people.apache.org/~simonetripodi/
http://www.99soft.org/



On Sun, Aug 29, 2010 at 9:28 AM, Tony Chemit <ch...@codelutin.com> wrote:
> Le Sat, 28 Aug 2010 16:22:29 +0200,
> Simone Tripodi <si...@gmail.com> a écrit :
>
>> Hi all guys,
>> a friend of mine and I are developing a maven plugin that needs to
>> acces to a server credentials specified in the settings.xml; no
>> problem since the org.apache.maven.settings.Server class exposes
>> methods to retrieve username/password, the problem comes when
>> passwords are encrypted using the method described in the
>> guide-encryption[1].
>> How can we decrypt the password inside the plugin code? Thanks in advance!
>
> Otherwise you change the goal share-server-secret of the org.nuiton:maven-helper-plugin which does it for you and make it avaible in your maven build. [2] and [3]
>
> And look at the code of mojo as well :) [4]
>
>> All the best,
>> Simo
>>
>> [1] http://maven.apache.org/guides/mini/guide-encryption.html
>
> [2] http://repo2.maven.org/maven2/org/nuiton/maven-helper-plugin/1.2.6/
> [3] http://maven-site.nuiton.org/maven-helper-plugin/share-server-secret-mojo.html
> [4] http://www.nuiton.org/repositories/entry/maven-helper-plugin/tags/maven-helper-plugin-1.2.6/src/main/java/org/nuiton/helper/plugin/ShareServerSecretPlugin.java
>>
>> http://people.apache.org/~simonetripodi/
>> http://www.99soft.org/
>>
>> ---------------------------------------------------------------------
>> To unsubscribe, e-mail: users-unsubscribe@maven.apache.org
>> For additional commands, e-mail: users-help@maven.apache.org
>>
>
> --
> Tony Chemit
> --------------------
> tél: +33 (0) 2 40 50 29 28
> email: chemit@codelutin.com
> http://www.codelutin.com
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscribe@maven.apache.org
> For additional commands, e-mail: users-help@maven.apache.org
>
>

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@maven.apache.org
For additional commands, e-mail: users-help@maven.apache.org


Re: Decrypting server password

Posted by Tony Chemit <ch...@codelutin.com>.
Le Sat, 28 Aug 2010 16:22:29 +0200,
Simone Tripodi <si...@gmail.com> a écrit :

> Hi all guys,
> a friend of mine and I are developing a maven plugin that needs to
> acces to a server credentials specified in the settings.xml; no
> problem since the org.apache.maven.settings.Server class exposes
> methods to retrieve username/password, the problem comes when
> passwords are encrypted using the method described in the
> guide-encryption[1].
> How can we decrypt the password inside the plugin code? Thanks in advance!

Otherwise you change the goal share-server-secret of the org.nuiton:maven-helper-plugin which does it for you and make it avaible in your maven build. [2] and [3]

And look at the code of mojo as well :) [4]

> All the best,
> Simo
> 
> [1] http://maven.apache.org/guides/mini/guide-encryption.html

[2] http://repo2.maven.org/maven2/org/nuiton/maven-helper-plugin/1.2.6/ 
[3] http://maven-site.nuiton.org/maven-helper-plugin/share-server-secret-mojo.html 
[4] http://www.nuiton.org/repositories/entry/maven-helper-plugin/tags/maven-helper-plugin-1.2.6/src/main/java/org/nuiton/helper/plugin/ShareServerSecretPlugin.java 
> 
> http://people.apache.org/~simonetripodi/
> http://www.99soft.org/
> 
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscribe@maven.apache.org
> For additional commands, e-mail: users-help@maven.apache.org
> 

-- 
Tony Chemit
--------------------
tél: +33 (0) 2 40 50 29 28
email: chemit@codelutin.com  
http://www.codelutin.com 

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@maven.apache.org
For additional commands, e-mail: users-help@maven.apache.org