Commit 9d80a013 authored by Gaston Dombiak's avatar Gaston Dombiak Committed by gato

Ported changes from TRUNK.

git-svn-id: http://svn.igniterealtime.org/svn/repos/wildfire/branches/3_0_branch@4403 b35dd754-fafc-0310-a699-88a17e54d16e
parent f1154c68
...@@ -4,79 +4,188 @@ ...@@ -4,79 +4,188 @@
<head> <head>
<title>User Import/Export Plugin Changelog</title> <title>User Import/Export Plugin Changelog</title>
<style type="text/css"> <style type="text/css">
BODY { /* global font and body settings */
font-size : 100%; body {
} font-size : 100%;
background-color : #d3d6d9;
BODY, TD, TH { padding: 0px;
font-family : tahoma, verdana, arial, helvetica, sans-serif; margin: 0px 0px 30px 0px;
font-size : 0.8em; }
} body, td, th {
font-family : arial, helvetica, sans-serif;
H2 { font-size : 10pt;
font-size : 10pt; }
font-weight : bold; pre, tt, code {
padding-left : 1em; font-family : courier new, monospaced;
} font-size : 9pt;
}
A:hover { #pageContainer {
text-decoration : none; display: block;
} position: relative;
clear: both;
H1 { background-color: #fff;
font-family : tahoma, arial, helvetica, sans-serif; border: 1px solid #999;
font-size : 1.4em; padding: 40px;
font-weight: bold; margin: 30px;
border-bottom : 1px #ccc solid; -moz-border-radius: 6px;
padding-bottom : 2px; }
} #pageHeader {
display: block;
TT { position: relative;
font-family : courier new; height: 80px;
font-weight : bold; background-color: #e7eaee;
color : #060; border: 1px solid #cccccc;
} border-bottom: none;
-moz-border-radius: 5px 5px 0px 0px;
PRE { margin: 10px 0px 0px 0px;
font-family : courier new; }
font-size : 100%; #pageBody {
} margin: 0px 18px 0px 20px;
}
/* anchors */
a:link {
color: #11568c;
}
a:visited {
color: #571c8d;
}
a:hover {
color: #7a1d42;
text-decoration : underline;
}
a:active {
color: #7a1d42;
}
/* page header elements (logo and navigation) */
.navigation {
display: block;
position: relative;
height: 20px;
background-color: #335588;
border: 1px solid #cccccc;
border-top: none;
color: #ffffff;
font-size: 11px;
line-height: 18px;
padding: 0px 0px 0px 0px;
margin: 0px 0px 25px 0px;
overflow: hidden;
}
.navigation a {
margin: 0px 20px 0px 20px;
}
.navigation a:link { color: #ffffff; }
.navigation a:visited { color: #ffffff; }
.navigation a:hover { color: #ffffff; }
.navigation a:active { color: #ffffff; }
/* headings */
h1 {
display: block;
position: relative;
font-size : 1.7em;
font-weight : bold;
color: #670e15;
padding: 0px;
margin: 30px 0px 0px 20px;
}
h2 {
font-size : 1.3em;
font-weight : bold;
margin: 40px 0px 6px 0px;
padding: 0px;
color: #335588;
}
h3 {
font-size : 1.0em;
font-weight : bold;
margin: 25px 0px 3px 0px;
padding: 0px;
color: #334466;
}
/* general elements */
p {
margin: 0px 0px 15px 0px;
}
ul {
margin: 5px 0px 15px 35px;
}
li {
padding-bottom : 4px;
}
tt {
font-family : courier new;
font-weight : bold;
color : #060;
}
hr {
display: block;
height: 1px;
background-color: #999999;
border: none;
margin: 40px 0px 20px 0px;
}
.footer {
font-size : 8pt;
color : #666;
text-align : center;
margin-top : 2em;
padding-top : 0.5em;
border-top : 1px #CCC solid;
}
</style> </style>
</head> </head>
<body> <body>
<h1>
User Import/Export Plugin Changelog
</h1>
<p><b>2.0.2</b> -- December 15, 2005</p> <div id="pageContainer">
<div id="pageHeader">
<h1>User Import/Export Plugin Changelog</h1>
</div>
<div id="pageBody">
<h2>2.0.3 -- <span style="font-weight: normal;">July 10, 2006</span></h2>
<ul>
<li>Updated to work with Wildfire 3.0.1.</li>
</ul>
<h2>2.0.2 -- <span style="font-weight: normal;">December 15, 2005</span></h2>
<ul> <ul>
<li>Now requires Wildfire 2.4.0</li> <li>Now requires Wildfire 2.4.0.</li>
</ul> </ul>
<p><b>2.0.1</b> -- November 29, 2005</p> <h2>2.0.1 -- <span style="font-weight: normal;">November 29, 2005</span></h2>
<ul> <ul>
<li>Fixed issue where SiteMesh was inserting html in the user export file. <li>Fixed issue where SiteMesh was inserting html in the user export file.
</ul> </ul>
<p><b>2.0</b> -- September 1, 2005</p> <h2>2.0 -- <span style="font-weight: normal;">September 1, 2005</span></h2>
<ul> <ul>
<li>Added the ability to allow users to specify the import and export file locations. <li>Added the ability to allow users to specify the import and export file locations.
<li>[<a href="http://www.jivesoftware.org/issues/browse/JM-369">JM-369</a>] - Add option to replace old domain with new domain while doing an import. <li>[<a href="http://www.jivesoftware.org/issues/browse/JM-369">JM-369</a>] - Add option to replace old domain with new domain while doing an import.
<li>Added additional information to the migration section of the readme file. <li>Added additional information to the migration section of the readme file.
</ul> </ul>
<p><b>1.0.1</b> -- June 30, 2005</p> <h2>1.0.1 -- <span style="font-weight: normal;">June 30, 2005</span></h2>
<ul> <ul>
<li>Added the ability to send export data directly to the screen.</li> <li>Added the ability to send export data directly to the screen.</li>
<li>Fixed compatibility issue with Wildfire version 2.1.4 and 2.1.5.</li> <li>Fixed compatibility issue with Wildfire version 2.1.4 and 2.1.5.</li>
<li>Refactored the code that creates the output directory to try and alleviate permission issues on Unix installations.</li> <li>Refactored the code that creates the output directory to try and alleviate permission issues on Unix installations.</li>
</ul> </ul>
<p><b>1.0</b> -- June 1, 2005</p> <h2>1.0 -- <span style="font-weight: normal;">June 1, 2005</span></h2>
<ul> <ul>
<li>Initial release.</li> <li>Initial release.</li>
</ul> </ul>
</div>
</div>
</body> </body>
</html> </html>
\ No newline at end of file
...@@ -4,11 +4,11 @@ ...@@ -4,11 +4,11 @@
<class>org.jivesoftware.wildfire.plugin.ImportExportPlugin</class> <class>org.jivesoftware.wildfire.plugin.ImportExportPlugin</class>
<name>User Import Export</name> <name>User Import Export</name>
<description>Enables import and export of user data.</description> <description>Enables import and export of user data</description>
<author>Ryan Graham</author> <author>Ryan Graham</author>
<version>2.0.2</version> <version>2.0.3</version>
<date>12/15/2005</date> <date>7/13/2006</date>
<minServerVersion>2.4.0</minServerVersion> <minServerVersion>3.0.1</minServerVersion>
<adminconsole> <adminconsole>
<tab id="tab-users"> <tab id="tab-users">
......
...@@ -4,66 +4,169 @@ ...@@ -4,66 +4,169 @@
<head> <head>
<title>User Import/Export Plugin Readme</title> <title>User Import/Export Plugin Readme</title>
<style type="text/css"> <style type="text/css">
BODY { /* global font and body settings */
font-size : 100%; body {
} font-size : 100%;
background-color : #d3d6d9;
BODY, TD, TH { padding: 0px;
font-family : tahoma, verdana, arial, helvetica, sans-serif; margin: 0px 0px 30px 0px;
font-size : 0.8em; }
} body, td, th {
font-family : arial, helvetica, sans-serif;
H2 { font-size : 10pt;
font-size : 11pt; }
font-weight : bold; pre, tt, code {
} font-family : courier new, monospaced;
font-size : 9pt;
A:hover { }
text-decoration : none; #pageContainer {
} display: block;
position: relative;
H1 { clear: both;
font-family : tahoma, arial, helvetica, sans-serif; background-color: #fff;
font-size : 1.4em; border: 1px solid #999;
font-weight: bold; padding: 40px;
border-bottom : 1px #ccc solid; margin: 30px;
padding-bottom : 2px; -moz-border-radius: 6px;
} }
#pageHeader {
display: block;
position: relative;
height: 80px;
background-color: #e7eaee;
border: 1px solid #cccccc;
border-bottom: none;
-moz-border-radius: 5px 5px 0px 0px;
margin: 10px 0px 0px 0px;
}
#pageBody {
margin: 0px 18px 0px 20px;
}
TT { /* anchors */
font-family : courier new; a:link {
font-weight : bold; color: #11568c;
color : #060; }
} a:visited {
color: #571c8d;
PRE { }
font-family : courier new; a:hover {
font-size : 100%; color: #7a1d42;
} text-decoration : underline;
}
#datatable TH { a:active {
color : #fff; color: #7a1d42;
background-color : #2A448C; }
text-align : left;
} /* page header elements (logo and navigation) */
.navigation {
#datatable TD { display: block;
background-color : #FAF6EF; position: relative;
} height: 20px;
background-color: #335588;
#datatable .name { border: 1px solid #cccccc;
background-color : #DCE2F5; border-top: none;
text-align : center; color: #ffffff;
} font-size: 11px;
line-height: 18px;
#xmltable TD { padding: 0px 0px 0px 0px;
background-color : #C3FDB8; margin: 0px 0px 25px 0px;
} overflow: hidden;
}
.navigation a {
margin: 0px 20px 0px 20px;
}
.navigation a:link { color: #ffffff; }
.navigation a:visited { color: #ffffff; }
.navigation a:hover { color: #ffffff; }
.navigation a:active { color: #ffffff; }
/* headings */
h1 {
display: block;
position: relative;
font-size : 1.7em;
font-weight : bold;
color: #670e15;
padding: 0px;
margin: 30px 0px 0px 20px;
}
h2 {
font-size : 1.3em;
font-weight : bold;
margin: 40px 0px 6px 0px;
padding: 0px;
color: #335588;
}
h3 {
font-size : 1.0em;
font-weight : bold;
margin: 25px 0px 3px 0px;
padding: 0px;
color: #334466;
}
/* general elements */
p {
margin: 0px 0px 15px 0px;
}
ul {
margin: 5px 0px 15px 35px;
}
li {
padding-bottom : 4px;
}
tt {
font-family : courier new;
font-weight : bold;
color : #060;
}
hr {
display: block;
height: 1px;
background-color: #999999;
border: none;
margin: 40px 0px 20px 0px;
}
.footer {
font-size : 8pt;
color : #666;
text-align : center;
margin-top : 2em;
padding-top : 0.5em;
border-top : 1px #CCC solid;
}
.datatable TH {
color : #fff;
background-color : #2A448C;
text-align : left;
}
.datatable TD {
background-color : #FAF6EF;
}
.datatable .name {
background-color : #DCE2F5;
text-align : center;
}
.xmltable TD {
background-color : #EFEFEF;
}
</style> </style>
</head> </head>
<body> <body>
<h1>User Import/Export Plugin Readme</h1> <div id="pageContainer">
<div id="pageHeader">
<h1>User Import/Export Plugin Readme</h1>
</div>
<div id="pageBody">
<h2>Overview</h2> <h2>Overview</h2>
<p>The user import/export plugin provides a way to import and export Wildfire user data via <p>The user import/export plugin provides a way to import and export Wildfire user data via
...@@ -111,7 +214,7 @@ whose roster looks like: ...@@ -111,7 +214,7 @@ whose roster looks like:
</li> </li>
<br> <br>
<div id="xmltable"> <div class="xmltable">
<table> <table>
<tr> <tr>
<td> <td>
...@@ -144,7 +247,7 @@ effect, the import file would be transformed to look like: ...@@ -144,7 +247,7 @@ effect, the import file would be transformed to look like:
<br> <br>
<br> <br>
<div id="xmltable"> <div class="xmltable">
<table> <table>
<tr> <tr>
<td> <td>
...@@ -176,7 +279,7 @@ have added each other to their respective rosters. ...@@ -176,7 +279,7 @@ have added each other to their respective rosters.
<br> <br>
<br> <br>
<div id="xmltable"> <div class="xmltable">
<table> <table>
<tr> <tr>
<td> <td>
...@@ -221,7 +324,7 @@ Below is a list of the different status types and what their associated numbers ...@@ -221,7 +324,7 @@ Below is a list of the different status types and what their associated numbers
<br> <br>
<br> <br>
<div id="datatable"> <div class="datatable">
<table cellpadding="3" cellspacing="1" border="0" width="700"> <table cellpadding="3" cellspacing="1" border="0" width="700">
<thead> <thead>
<tr> <tr>
...@@ -302,5 +405,9 @@ Below is a list of the different status types and what their associated numbers ...@@ -302,5 +405,9 @@ Below is a list of the different status types and what their associated numbers
</tbody> </tbody>
</table> </table>
</div> </div>
</div>
</div>
</body> </body>
</html> </html>
\ No newline at end of file
...@@ -9,6 +9,7 @@ import org.dom4j.io.OutputFormat; ...@@ -9,6 +9,7 @@ import org.dom4j.io.OutputFormat;
import org.dom4j.io.SAXReader; import org.dom4j.io.SAXReader;
import org.dom4j.io.XMLWriter; import org.dom4j.io.XMLWriter;
import org.jivesoftware.wildfire.XMPPServer; import org.jivesoftware.wildfire.XMPPServer;
import org.jivesoftware.wildfire.auth.AuthFactory;
import org.jivesoftware.wildfire.container.Plugin; import org.jivesoftware.wildfire.container.Plugin;
import org.jivesoftware.wildfire.container.PluginManager; import org.jivesoftware.wildfire.container.PluginManager;
import org.jivesoftware.wildfire.roster.RosterItem; import org.jivesoftware.wildfire.roster.RosterItem;
...@@ -43,6 +44,7 @@ import java.util.StringTokenizer; ...@@ -43,6 +44,7 @@ import java.util.StringTokenizer;
* @author Ryan Graham * @author Ryan Graham
*/ */
public class ImportExportPlugin implements Plugin { public class ImportExportPlugin implements Plugin {
private UserManager userManager; private UserManager userManager;
private UserProvider provider; private UserProvider provider;
...@@ -122,7 +124,7 @@ public class ImportExportPlugin implements Plugin { ...@@ -122,7 +124,7 @@ public class ImportExportPlugin implements Plugin {
userElement.addElement("Username").addText(userName); userElement.addElement("Username").addText(userName);
try { try {
userElement.addElement("Password").addText(provider.getPassword(user.getUsername())); userElement.addElement("Password").addText(AuthFactory.getPassword(user.getUsername()));
} }
catch (UserNotFoundException e) { catch (UserNotFoundException e) {
//this should never happen //this should never happen
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment