mirror of
https://github.com/DSpace/DSpace.git
synced 2025-10-07 01:54:22 +00:00
Compare commits
49 Commits
test_merge
...
dspace-3.2
Author | SHA1 | Date | |
---|---|---|---|
![]() |
25208859e7 | ||
![]() |
98b94abe9e | ||
![]() |
fbf5834ac6 | ||
![]() |
435452f669 | ||
![]() |
3dcd352f88 | ||
![]() |
5ab9cb63d9 | ||
![]() |
2fc1877502 | ||
![]() |
a27254f8c5 | ||
![]() |
3c65eddd5f | ||
![]() |
3336594917 | ||
![]() |
60121cba95 | ||
![]() |
dbd6b24407 | ||
![]() |
16bb726547 | ||
![]() |
0db24ca219 | ||
![]() |
5a6f771c8f | ||
![]() |
de614e9255 | ||
![]() |
9ff5438aa6 | ||
![]() |
ba5784c81f | ||
![]() |
ccdcb13425 | ||
![]() |
464c1db7b3 | ||
![]() |
026b61f100 | ||
![]() |
3dcecf099f | ||
![]() |
6dfef6921e | ||
![]() |
618ab11e58 | ||
![]() |
f2ed822881 | ||
![]() |
bc35abe279 | ||
![]() |
26c6ea1859 | ||
![]() |
52bef81f15 | ||
![]() |
8bc185f7cf | ||
![]() |
e3bab72e68 | ||
![]() |
8fe4bd3dab | ||
![]() |
5217ac40a9 | ||
![]() |
0270301de4 | ||
![]() |
9caf1f3357 | ||
![]() |
d971eba45f | ||
![]() |
d48a5f7086 | ||
![]() |
91de08756e | ||
![]() |
f92a42d1a8 | ||
![]() |
626f1f7967 | ||
![]() |
41ec78907a | ||
![]() |
7be7f132bb | ||
![]() |
491c3eaeb6 | ||
![]() |
ee51662039 | ||
![]() |
f6862fe849 | ||
![]() |
b2443c6168 | ||
![]() |
64c046b095 | ||
![]() |
c707deb4f0 | ||
![]() |
60ea3f1a32 | ||
![]() |
037d41f336 |
6
.gitignore
vendored
6
.gitignore
vendored
@@ -22,6 +22,6 @@ nbactions.xml
|
||||
nb-configuration.xml
|
||||
META-INF/
|
||||
|
||||
## Ignore all *.properties file, EXCEPT build.properties (the default)
|
||||
*.properties
|
||||
!build.properties
|
||||
## Ignore all *.properties file in root folder, EXCEPT build.properties (the default)
|
||||
/*.properties
|
||||
!/build.properties
|
@@ -12,7 +12,7 @@
|
||||
<parent>
|
||||
<groupId>org.dspace</groupId>
|
||||
<artifactId>dspace-parent</artifactId>
|
||||
<version>4.0-SNAPSHOT</version>
|
||||
<version>3.2</version>
|
||||
<relativePath>..</relativePath>
|
||||
</parent>
|
||||
|
||||
@@ -423,6 +423,12 @@
|
||||
<version>0.18.6</version>
|
||||
</dependency>
|
||||
|
||||
<dependency>
|
||||
<groupId>com.coverity.security</groupId>
|
||||
<artifactId>coverity-escapers</artifactId>
|
||||
<version>1.1.1</version>
|
||||
</dependency>
|
||||
|
||||
<!-- Gson: Java to Json conversion -->
|
||||
<dependency>
|
||||
<groupId>com.google.code.gson</groupId>
|
||||
|
@@ -612,7 +612,7 @@ public class LDAPAuthentication
|
||||
|
||||
/*
|
||||
* Add authenticated users to the group defined in dspace.cfg by
|
||||
* the ldap.login.groupmap.* key.
|
||||
* the authentication-ldap.login.groupmap.* key.
|
||||
*/
|
||||
private void assignGroupsBasedOnLdapDn(String dn, Context context)
|
||||
{
|
||||
@@ -644,7 +644,7 @@ public class LDAPAuthentication
|
||||
// The group does not exist
|
||||
log.warn(LogManager.getHeader(context,
|
||||
"ldap_assignGroupsBasedOnLdapDn",
|
||||
"Group defined in ldap.login.groupmap." + i + " does not exist :: " + dspaceGroupName));
|
||||
"Group defined in authentication-ldap.login.groupmap." + i + " does not exist :: " + dspaceGroupName));
|
||||
}
|
||||
}
|
||||
catch (AuthorizeException ae)
|
||||
@@ -657,7 +657,7 @@ public class LDAPAuthentication
|
||||
}
|
||||
}
|
||||
|
||||
groupMap = ConfigurationManager.getProperty("ldap.login.groupmap." + ++i);
|
||||
groupMap = ConfigurationManager.getProperty("authentication-ldap", "login.groupmap." + ++i);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
@@ -26,7 +26,7 @@ import java.util.Calendar;
|
||||
import java.util.GregorianCalendar;
|
||||
import java.text.SimpleDateFormat;
|
||||
import java.text.ParseException;
|
||||
|
||||
import com.coverity.security.Escape;
|
||||
import org.apache.log4j.Logger;
|
||||
|
||||
/**
|
||||
@@ -280,21 +280,7 @@ public final class Utils
|
||||
*/
|
||||
public static String addEntities(String value)
|
||||
{
|
||||
if (value==null || value.length() == 0)
|
||||
{
|
||||
return value;
|
||||
}
|
||||
|
||||
value = value.replaceAll("&", "&");
|
||||
value = value.replaceAll("\"", """);
|
||||
|
||||
// actually, ' is an XML entity, not in HTML.
|
||||
// that's why it's commented out.
|
||||
// value = value.replaceAll("'", "'");
|
||||
value = value.replaceAll("<", "<");
|
||||
value = value.replaceAll(">", ">");
|
||||
|
||||
return value;
|
||||
return Escape.html(value);
|
||||
}
|
||||
|
||||
/**
|
||||
|
@@ -13,7 +13,7 @@
|
||||
<parent>
|
||||
<groupId>org.dspace</groupId>
|
||||
<artifactId>dspace-parent</artifactId>
|
||||
<version>4.0-SNAPSHOT</version>
|
||||
<version>3.2</version>
|
||||
<relativePath>..</relativePath>
|
||||
</parent>
|
||||
|
||||
|
@@ -45,8 +45,8 @@ public class LDAPServlet extends DSpaceServlet
|
||||
HttpServletResponse response)
|
||||
throws ServletException, IOException, SQLException, AuthorizeException
|
||||
{
|
||||
// check if ldap is enables and forward to the correct login form
|
||||
boolean ldap_enabled = ConfigurationManager.getBooleanProperty("ldap.enable");
|
||||
// check if ldap is enables and forward to the correct login form
|
||||
boolean ldap_enabled = ConfigurationManager.getBooleanProperty("authentication-ldap", "enable");
|
||||
if (ldap_enabled)
|
||||
{
|
||||
JSPManager.showJSP(request, response, "/login/ldap.jsp");
|
||||
@@ -104,4 +104,4 @@ public class LDAPServlet extends DSpaceServlet
|
||||
"netid=" + netid + ", result=" + String.valueOf(status)));
|
||||
JSPManager.showJSP(request, response, jsp);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
@@ -74,9 +74,6 @@
|
||||
<filter-mapping>
|
||||
<filter-name>dspace.request</filter-name>
|
||||
<url-pattern>/*</url-pattern>
|
||||
<dispatcher>REQUEST</dispatcher>
|
||||
<dispatcher>FORWARD</dispatcher>
|
||||
<dispatcher>INCLUDE</dispatcher>
|
||||
</filter-mapping>
|
||||
|
||||
<filter-mapping>
|
||||
|
@@ -27,6 +27,7 @@
|
||||
<%@ taglib uri="http://www.dspace.org/dspace-tags.tld" prefix="dspace" %>
|
||||
|
||||
<%@ page import="org.dspace.eperson.EPerson" %>
|
||||
<%@ page import="org.dspace.core.Utils" %>
|
||||
|
||||
<%
|
||||
EPerson[] epeople =
|
||||
@@ -115,10 +116,10 @@
|
||||
<%= (e.getEmail() == null ? "" : e.getEmail()) %>
|
||||
</td>
|
||||
<td headers="t3" class="<%= row %>RowOddCol">
|
||||
<%= (e.getLastName() == null ? "" : e.getLastName()) %>
|
||||
<%= (e.getLastName() == null ? "" : Utils.addEntities(e.getLastName())) %>
|
||||
</td>
|
||||
<td headers="t4" class="<%= row %>RowEvenCol">
|
||||
<%= (e.getFirstName() == null ? "" : e.getFirstName()) %>
|
||||
<%= (e.getFirstName() == null ? "" : Utils.addEntities(e.getFirstName())) %>
|
||||
</td>
|
||||
<td headers="t5" class="<%= row %>RowOddCol" align="center">
|
||||
<%= e.canLogIn() ? "yes" : "no" %>
|
||||
@@ -130,7 +131,7 @@
|
||||
<%= e.getSelfRegistered() ? "yes" : "no" %>
|
||||
</td>
|
||||
<td headers="t8" class="<%= row %>RowEvenCol">
|
||||
<%= (e.getMetadata("phone") == null ? "" : e.getMetadata("phone")) %>
|
||||
<%= (e.getMetadata("phone") == null ? "" : Utils.addEntities(e.getMetadata("phone"))) %>
|
||||
</td>
|
||||
<td headers="t9" class="<%= row %>RowOddCol">
|
||||
<input type="hidden" name="eperson_id" value="<%= e.getID() %>"/>
|
||||
|
@@ -20,6 +20,7 @@
|
||||
prefix="fmt" %>
|
||||
|
||||
<%@ page import="org.dspace.eperson.EPerson" %>
|
||||
<%@ page import="org.dspace.core.Utils" %>
|
||||
|
||||
<%@ taglib uri="http://www.dspace.org/dspace-tags.tld" prefix="dspace" %>
|
||||
|
||||
@@ -32,9 +33,9 @@
|
||||
parenttitlekey="jsp.administer"
|
||||
parentlink="/dspace-admin">
|
||||
|
||||
<%-- <h1>Delete e-person: <%= eperson.getFullName() %> (<%= eperson.getEmail() %>)</h1> --%>
|
||||
<%-- <h1>Delete e-person: <%= Utils.addEntities(eperson.getFullName()) %> (<%= eperson.getEmail() %>)</h1> --%>
|
||||
<h1><fmt:message key="jsp.dspace-admin.eperson-confirm-delete.heading">
|
||||
<fmt:param><%= eperson.getFullName() %></fmt:param>
|
||||
<fmt:param><%= Utils.addEntities(eperson.getFullName()) %></fmt:param>
|
||||
<fmt:param><%= eperson.getEmail() %></fmt:param>
|
||||
</fmt:message></h1>
|
||||
|
||||
|
@@ -28,11 +28,12 @@
|
||||
<%@ page import="org.dspace.eperson.EPerson" %>
|
||||
<%@ page import="java.util.List" %>
|
||||
<%@ page import="java.util.Iterator" %>
|
||||
<%@ page import="org.dspace.core.Utils" %>
|
||||
|
||||
<%
|
||||
EPerson eperson = (EPerson) request.getAttribute("eperson");
|
||||
List tableList = (List) request.getAttribute("tableList");
|
||||
String fullName = eperson.getFullName();
|
||||
String fullName = Utils.addEntities(eperson.getFullName());
|
||||
Iterator tableIt = tableList.iterator();
|
||||
|
||||
%>
|
||||
|
@@ -28,6 +28,7 @@
|
||||
<%@ page import="org.dspace.eperson.EPerson" %>
|
||||
<%@ page import="org.dspace.eperson.Group" %>
|
||||
<%@ page import="org.dspace.content.WorkspaceItem" %>
|
||||
<%@ page import="org.dspace.core.Utils" %>
|
||||
|
||||
<%
|
||||
// get item and group out of the request
|
||||
@@ -75,7 +76,7 @@
|
||||
<br/><br/>
|
||||
<strong><fmt:message key="jsp.dspace-admin.supervise-confirm-remove.authorheader"/></strong>:
|
||||
<br/>
|
||||
<a href="mailto:<%= submitter.getEmail() %>"><%= submitter.getFullName() %></a>
|
||||
<a href="mailto:<%= submitter.getEmail() %>"><%= Utils.addEntities(submitter.getFullName()) %></a>
|
||||
<br/><br/>
|
||||
<strong><fmt:message key="jsp.dspace-admin.supervise-confirm-remove.supervisorgroupheader"/></strong>:
|
||||
<br/>
|
||||
|
@@ -28,6 +28,7 @@
|
||||
<%@ page import="org.dspace.eperson.EPerson" %>
|
||||
<%@ page import="org.dspace.eperson.Group" %>
|
||||
<%@ page import="org.dspace.eperson.Supervisor" %>
|
||||
<%@ page import="org.dspace.core.Utils" %>
|
||||
|
||||
<%
|
||||
// get objects from request
|
||||
@@ -109,7 +110,7 @@
|
||||
<%= workspaceItems[i].getID() %>
|
||||
</td>
|
||||
<td class="<%= row %>RowEvenCol">
|
||||
<a href="mailto:<%= submitter.getEmail() %>"><%= submitter.getFullName() %></a>
|
||||
<a href="mailto:<%= submitter.getEmail() %>"><%= Utils.addEntities(submitter.getFullName()) %></a>
|
||||
</td>
|
||||
<td class="<%= row %>RowOddCol">
|
||||
<%
|
||||
|
@@ -25,6 +25,7 @@
|
||||
<%@ page import="org.dspace.content.SupervisedItem" %>
|
||||
<%@ page import="org.dspace.eperson.EPerson" %>
|
||||
<%@ page import="org.dspace.eperson.Group" %>
|
||||
<%@ page import="org.dspace.core.Utils" %>
|
||||
|
||||
<%
|
||||
// get the object array out of the request
|
||||
@@ -97,7 +98,7 @@
|
||||
<%= supervisors[j].getName() %>
|
||||
</td>
|
||||
<td class="<%= row %>RowOddCol">
|
||||
<a href="mailto:<%= submitter.getEmail() %>"><%= submitter.getFullName() %></a>
|
||||
<a href="mailto:<%= submitter.getEmail() %>"><%= Utils.addEntities(submitter.getFullName()) %></a>
|
||||
</td>
|
||||
<td class="<%= row %>RowEvenCol">
|
||||
<%
|
||||
|
@@ -25,7 +25,6 @@
|
||||
<%@ taglib uri="http://java.sun.com/jsp/jstl/fmt"
|
||||
prefix="fmt" %>
|
||||
|
||||
|
||||
<%@ taglib uri="http://www.dspace.org/dspace-tags.tld" prefix="dspace" %>
|
||||
|
||||
<%@ page import="javax.servlet.jsp.jstl.fmt.LocaleSupport" %>
|
||||
@@ -78,7 +77,7 @@
|
||||
<tr>
|
||||
<td align="left">
|
||||
<h1>
|
||||
<fmt:message key="jsp.mydspace"/>: <%= user.getFullName() %>
|
||||
<fmt:message key="jsp.mydspace"/>: <%= Utils.addEntities(user.getFullName()) %>
|
||||
</h1>
|
||||
</td>
|
||||
<td align="right" class="standard">
|
||||
@@ -136,7 +135,7 @@
|
||||
</td>
|
||||
<td headers="t2" class="<%= row %>RowEvenCol"><%= Utils.addEntities(title) %></td>
|
||||
<td headers="t3" class="<%= row %>RowOddCol"><%= owned[i].getCollection().getMetadata("name") %></td>
|
||||
<td headers="t4" class="<%= row %>RowEvenCol"><a href="mailto:<%= submitter.getEmail() %>"><%= submitter.getFullName() %></a></td>
|
||||
<td headers="t4" class="<%= row %>RowEvenCol"><a href="mailto:<%= submitter.getEmail() %>"><%= Utils.addEntities(submitter.getFullName()) %></a></td>
|
||||
<!-- <td headers="t5" class="<%= row %>RowOddCol"></td> -->
|
||||
<td headers="t5" class="<%= row %>RowEvenCol">
|
||||
<form action="<%= request.getContextPath() %>/mydspace" method="post">
|
||||
@@ -200,7 +199,7 @@
|
||||
</td>
|
||||
<td headers="t7" class="<%= row %>RowEvenCol"><%= Utils.addEntities(title) %></td>
|
||||
<td headers="t8" class="<%= row %>RowOddCol"><%= pooled[i].getCollection().getMetadata("name") %></td>
|
||||
<td headers="t9" class="<%= row %>RowEvenCol"><a href="mailto:<%= submitter.getEmail() %>"><%= submitter.getFullName() %></a></td>
|
||||
<td headers="t9" class="<%= row %>RowEvenCol"><a href="mailto:<%= submitter.getEmail() %>"><%= Utils.addEntities(submitter.getFullName()) %></a></td>
|
||||
<td class="<%= row %>RowOddCol">
|
||||
<form action="<%= request.getContextPath() %>/mydspace" method="post">
|
||||
<input type="hidden" name="step" value="<%= MyDSpaceServlet.MAIN_PAGE %>" />
|
||||
@@ -285,7 +284,7 @@
|
||||
</form>
|
||||
</td>
|
||||
<td headers="t10" class="<%= row %>RowEvenCol">
|
||||
<a href="mailto:<%= submitter.getEmail() %>"><%= submitter.getFullName() %></a>
|
||||
<a href="mailto:<%= submitter.getEmail() %>"><%= Utils.addEntities(submitter.getFullName()) %></a>
|
||||
</td>
|
||||
<td headers="t11" class="<%= row %>RowOddCol"><%= Utils.addEntities(title) %></td>
|
||||
<td headers="t12" class="<%= row %>RowEvenCol"><%= workspaceItems[i].getCollection().getMetadata("name") %></td>
|
||||
@@ -332,7 +331,7 @@
|
||||
</form>
|
||||
</td>
|
||||
<td class="<%= row %>RowEvenCol">
|
||||
<a href="mailto:<%= submitter.getEmail() %>"><%= submitter.getFullName() %></a>
|
||||
<a href="mailto:<%= submitter.getEmail() %>"><%= Utils.addEntities(submitter.getFullName()) %></a>
|
||||
</td>
|
||||
<td class="<%= row %>RowOddCol"><%= Utils.addEntities(title) %></td>
|
||||
<td class="<%= row %>RowEvenCol"><%= supervisedItems[i].getCollection().getMetadata("name") %></td>
|
||||
|
@@ -29,6 +29,7 @@
|
||||
|
||||
<%@ page import="org.dspace.app.webui.servlet.RegisterServlet" %>
|
||||
<%@ page import="org.dspace.eperson.EPerson" %>
|
||||
<%@ page import="org.dspace.core.Utils" %>
|
||||
|
||||
<%
|
||||
EPerson eperson = (EPerson) request.getAttribute("eperson");
|
||||
@@ -43,9 +44,9 @@
|
||||
<%-- <h1>Enter a New Password</h1> --%>
|
||||
<h1><fmt:message key="jsp.register.new-password.title"/></h1>
|
||||
|
||||
<!-- <p>Hello <%= eperson.getFullName() %>,</p> -->
|
||||
<!-- <p>Hello <%= Utils.addEntities(eperson.getFullName()) %>,</p> -->
|
||||
<p><fmt:message key="jsp.register.new-password.hello">
|
||||
<fmt:param><%= eperson.getFullName() %></fmt:param>
|
||||
<fmt:param><%= Utils.addEntities(eperson.getFullName()) %></fmt:param>
|
||||
</fmt:message></p>
|
||||
|
||||
<%
|
||||
|
@@ -25,6 +25,7 @@
|
||||
|
||||
<%@ page import="org.dspace.app.webui.servlet.RegisterServlet" %>
|
||||
<%@ page import="org.dspace.eperson.EPerson" %>
|
||||
<%@ page import="org.dspace.core.Utils" %>
|
||||
|
||||
<%
|
||||
EPerson eperson = (EPerson) request.getAttribute("eperson");
|
||||
@@ -35,9 +36,9 @@
|
||||
<%-- <h1>Registration Complete</h1> --%>
|
||||
<h1><fmt:message key="jsp.register.registered.title"/></h1>
|
||||
|
||||
<%-- <p>Thank you <%= eperson.getFirstName() %>,</p> --%>
|
||||
<%-- <p>Thank you <%= Utils.addEntities(eperson.getFirstName()) %>,</p> --%>
|
||||
<p><fmt:message key="jsp.register.registered.thank">
|
||||
<fmt:param><%= eperson.getFirstName() %></fmt:param>
|
||||
<fmt:param><%= Utils.addEntities(eperson.getFirstName()) %></fmt:param>
|
||||
</fmt:message></p>
|
||||
|
||||
<%-- <p>You're now registered to use the DSpace system. You can subscribe to
|
||||
|
@@ -50,6 +50,7 @@
|
||||
<%@ page import="org.dspace.content.authority.ChoiceAuthorityManager" %>
|
||||
<%@ page import="org.dspace.content.authority.Choices" %>
|
||||
<%@ page import="org.dspace.core.ConfigurationManager" %>
|
||||
<%@ page import="org.dspace.core.Utils" %>
|
||||
|
||||
<%@ taglib uri="http://www.dspace.org/dspace-tags.tld" prefix="dspace" %>
|
||||
<%@ taglib uri="http://java.sun.com/jsp/jstl/fmt" prefix="fmt" %>
|
||||
@@ -325,9 +326,9 @@
|
||||
if (repeatable && !readonly && i < defaults.length)
|
||||
{
|
||||
name.setLength(0);
|
||||
name.append(dpn.getLastName())
|
||||
name.append(Utils.addEntities(dpn.getLastName()))
|
||||
.append(' ')
|
||||
.append(dpn.getFirstNames());
|
||||
.append(Utils.addEntities(dpn.getFirstNames()));
|
||||
// put a remove button next to filled in values
|
||||
sb.append("<td><input type=\"submit\" name=\"submit_")
|
||||
.append(fieldName)
|
||||
|
@@ -281,7 +281,7 @@ function clearEPeople()
|
||||
{
|
||||
EPerson e = epeople[i];
|
||||
// Make sure no quotes in full name will mess up our Javascript
|
||||
String fullname = e.getFullName().replace('\'', ' ');
|
||||
String fullname = Utils.addEntities(e.getFullName().replace('\'', ' '));
|
||||
%>
|
||||
<tr>
|
||||
<td headers="t1" class="<%= row %>RowOddCol">
|
||||
@@ -291,10 +291,10 @@ function clearEPeople()
|
||||
<td headers="t2" class="<%= row %>RowEvenCol"><%= e.getID() %></td>
|
||||
<td headers="t3" class="<%= row %>RowOddCol"><%= e.getEmail() %></td>
|
||||
<td headers="t4" class="<%= row %>RowEvenCol">
|
||||
<%= (e.getLastName() == null ? "" : e.getLastName()) %>
|
||||
<%= (e.getLastName() == null ? "" : Utils.addEntities(e.getLastName())) %>
|
||||
</td>
|
||||
<td headers="t5" class="<%= row %>RowOddCol">
|
||||
<%= (e.getFirstName() == null ? "" : e.getFirstName()) %>
|
||||
<%= (e.getFirstName() == null ? "" : Utils.addEntities(e.getFirstName())) %>
|
||||
</td>
|
||||
<td headers="t6" class="<%= row %>RowOddCol">
|
||||
<%= (e.getLanguage() == null ? "" : e.getLanguage()) %>
|
||||
|
@@ -26,6 +26,7 @@
|
||||
<%@ page import="org.dspace.content.WorkspaceItem" %>
|
||||
<%@ page import="org.dspace.eperson.EPerson" %>
|
||||
<%@ page import="javax.servlet.jsp.jstl.fmt.LocaleSupport" %>
|
||||
<%@ page import="org.dspace.core.Utils" %>
|
||||
|
||||
<%
|
||||
// get the workspace item from the request
|
||||
@@ -73,7 +74,7 @@
|
||||
}
|
||||
%>
|
||||
|
||||
<p><strong><a href="mailto:<%= submitter.getEmail() %>"><%= submitter.getFullName() %></a></strong></p>
|
||||
<p><strong><a href="mailto:<%= submitter.getEmail() %>"><%= Utils.addEntities(submitter.getFullName()) %></a></strong></p>
|
||||
|
||||
<p><fmt:message key="jsp.workspace.ws-main.submitmsg"/>
|
||||
<%= workspaceItem.getCollection().getMetadata("name") %></p>
|
||||
|
@@ -10,18 +10,33 @@
|
||||
|
||||
<parent>
|
||||
<groupId>org.dspace</groupId>
|
||||
<artifactId>dspace-lni</artifactId>
|
||||
<version>3.0-SNAPSHOT</version>
|
||||
<relativePath>..</relativePath>
|
||||
<artifactId>dspace-parent</artifactId>
|
||||
<version>3.2</version>
|
||||
<relativePath>../..</relativePath>
|
||||
</parent>
|
||||
|
||||
<properties>
|
||||
<!-- This is the path to the root [dspace-src] directory. -->
|
||||
<root.basedir>${basedir}/../..</root.basedir>
|
||||
</properties>
|
||||
|
||||
<!--
|
||||
Running this profile will regenerate (from WSDL) most of the classes
|
||||
under the 'org.dspace.app.dav.client' package, based on the existing
|
||||
'org.dspace.app.dav.LNISoapServlet' class in the dspace-lni API.
|
||||
|
||||
This profile is only activated if you explicitly run:
|
||||
mvn package -P regenerate-wsdl
|
||||
|
||||
Please note that after regenerating these classes, you will need to manually
|
||||
re-apply the DSpace license header, in order for them to pass license header
|
||||
checks executed during "mvn install" or "mvn release".
|
||||
-->
|
||||
<profiles>
|
||||
<profile>
|
||||
<id>regenerate-wsdl</id>
|
||||
<activation>
|
||||
<property>
|
||||
<name>regenerate-wsdl</name>
|
||||
<value>true</value>
|
||||
</property>
|
||||
<activeByDefault>false</activeByDefault>
|
||||
</activation>
|
||||
<build>
|
||||
<plugins>
|
||||
@@ -174,6 +189,12 @@
|
||||
<artifactId>servlet-api</artifactId>
|
||||
<scope>provided</scope>
|
||||
</dependency>
|
||||
<dependency>
|
||||
<groupId>org.dspace</groupId>
|
||||
<artifactId>dspace-lni</artifactId>
|
||||
<type>jar</type>
|
||||
<classifier>classes</classifier>
|
||||
</dependency>
|
||||
</dependencies>
|
||||
|
||||
</project>
|
||||
|
@@ -11,7 +11,7 @@
|
||||
<parent>
|
||||
<groupId>org.dspace</groupId>
|
||||
<artifactId>dspace-parent</artifactId>
|
||||
<version>4.0-SNAPSHOT</version>
|
||||
<version>3.2</version>
|
||||
<relativePath>..</relativePath>
|
||||
</parent>
|
||||
|
||||
|
@@ -8,7 +8,7 @@
|
||||
<parent>
|
||||
<artifactId>dspace-parent</artifactId>
|
||||
<groupId>org.dspace</groupId>
|
||||
<version>4.0-SNAPSHOT</version>
|
||||
<version>3.2</version>
|
||||
<relativePath>..</relativePath>
|
||||
</parent>
|
||||
|
||||
@@ -72,7 +72,7 @@
|
||||
<dependency>
|
||||
<groupId>com.lyncode</groupId>
|
||||
<artifactId>xoai</artifactId>
|
||||
<version>2.2.9</version>
|
||||
<version>3.0.0</version>
|
||||
</dependency>
|
||||
<dependency>
|
||||
<groupId>org.dspace</groupId>
|
||||
|
@@ -7,6 +7,8 @@
|
||||
*/
|
||||
package org.dspace.xoai.data;
|
||||
|
||||
import java.io.File;
|
||||
import java.io.IOException;
|
||||
import java.sql.SQLException;
|
||||
import java.util.ArrayList;
|
||||
import java.util.Date;
|
||||
@@ -14,6 +16,7 @@ import java.util.List;
|
||||
|
||||
import javax.servlet.http.HttpServletRequest;
|
||||
|
||||
import org.apache.commons.io.FileUtils;
|
||||
import org.apache.log4j.LogManager;
|
||||
import org.apache.log4j.Logger;
|
||||
import org.dspace.core.ConfigurationManager;
|
||||
@@ -157,4 +160,36 @@ public class DSpaceIdentify extends AbstractIdentify
|
||||
return _name;
|
||||
}
|
||||
|
||||
@Override
|
||||
public List<String> getDescription() {
|
||||
List<String> result = new ArrayList<String>();
|
||||
String descriptionFile = ConfigurationManager.getProperty("oai", "description.file");
|
||||
if (descriptionFile == null) {
|
||||
// Try indexed
|
||||
boolean stop = false;
|
||||
List<String> descriptionFiles = new ArrayList<String>();
|
||||
for (int i=0;!stop;i++) {
|
||||
String tmp = ConfigurationManager.getProperty("oai", "description.file."+i);
|
||||
if (tmp == null && i!=0) stop = true;
|
||||
else descriptionFiles.add(tmp);
|
||||
}
|
||||
|
||||
for (String path : descriptionFiles) {
|
||||
try {
|
||||
result.add(FileUtils.readFileToString(new File(path)));
|
||||
} catch (IOException e) {
|
||||
log.error(e.getMessage(), e);
|
||||
}
|
||||
}
|
||||
|
||||
} else {
|
||||
try {
|
||||
result.add(FileUtils.readFileToString(new File(descriptionFile)));
|
||||
} catch (IOException e) {
|
||||
log.error(e.getMessage(), e);
|
||||
}
|
||||
}
|
||||
return result;
|
||||
}
|
||||
|
||||
}
|
||||
|
@@ -156,7 +156,7 @@ public abstract class DSpaceItemRepository extends AbstractItemRepository
|
||||
public ListItemsResults getItemsUntil(List<Filter> filters, int offset,
|
||||
int length, String setSpec, Date from)
|
||||
{
|
||||
filters.add(new Filter(new DateFromFilter(from), FilterScope.Query));
|
||||
filters.add(new Filter(new DateUntilFilter(from), FilterScope.Query));
|
||||
filters.add(new Filter(new DspaceSetSpecFilter(setSpec),
|
||||
FilterScope.Query));
|
||||
return this.getItems(filters, offset, length);
|
||||
|
@@ -45,7 +45,6 @@ public class DateUntilFilter extends DSpaceFilter
|
||||
@Override
|
||||
public SolrFilterResult getQuery()
|
||||
{
|
||||
System.out.println("HEYYYY!!!!");
|
||||
return new SolrFilterResult("item.lastmodified:[* TO "
|
||||
+ ClientUtils.escapeQueryChars(DateUtils.formatToSolr(_date, false)) + "]");
|
||||
}
|
||||
|
@@ -165,7 +165,7 @@ public class ItemUtils
|
||||
Element bitstream = create(factory, "bitstream");
|
||||
bitstreams.getElement().add(bitstream);
|
||||
String url = "";
|
||||
String bsName = bitstream.getName();
|
||||
String bsName = bit.getName();
|
||||
String sid = String.valueOf(bit.getSequenceID());
|
||||
String baseUrl = ConfigurationManager.getProperty("oai",
|
||||
"bitstream.baseUrl");
|
||||
@@ -190,7 +190,7 @@ public class ItemUtils
|
||||
if (handle != null && baseUrl != null)
|
||||
{
|
||||
url = baseUrl + "/bitstream/"
|
||||
+ URLUtils.encode(handle) + "/"
|
||||
+ handle + "/"
|
||||
+ sid + "/"
|
||||
+ URLUtils.encode(bsName);
|
||||
}
|
||||
|
@@ -9,7 +9,7 @@
|
||||
<parent>
|
||||
<groupId>org.dspace</groupId>
|
||||
<artifactId>dspace-parent</artifactId>
|
||||
<version>4.0-SNAPSHOT</version>
|
||||
<version>3.2</version>
|
||||
</parent>
|
||||
|
||||
<properties>
|
||||
|
@@ -15,7 +15,7 @@
|
||||
<parent>
|
||||
<groupId>org.dspace</groupId>
|
||||
<artifactId>dspace-parent</artifactId>
|
||||
<version>4.0-SNAPSHOT</version>
|
||||
<version>3.2</version>
|
||||
<relativePath>..</relativePath>
|
||||
</parent>
|
||||
|
||||
|
@@ -13,7 +13,7 @@
|
||||
<parent>
|
||||
<groupId>org.dspace</groupId>
|
||||
<artifactId>dspace-parent</artifactId>
|
||||
<version>4.0-SNAPSHOT</version>
|
||||
<version>3.2</version>
|
||||
<relativePath>..</relativePath>
|
||||
</parent>
|
||||
|
||||
|
@@ -11,7 +11,7 @@
|
||||
<parent>
|
||||
<groupId>org.dspace</groupId>
|
||||
<artifactId>dspace-parent</artifactId>
|
||||
<version>4.0-SNAPSHOT</version>
|
||||
<version>3.2</version>
|
||||
<relativePath>..</relativePath>
|
||||
</parent>
|
||||
|
||||
|
@@ -178,17 +178,8 @@ and searching the repository.
|
||||
<map:serialize type="xml"/>
|
||||
</map:match>
|
||||
</map:match>
|
||||
|
||||
<map:match type="HandleAuthorizedMatcher" pattern="!READ">
|
||||
<map:transform type="RestrictedItem">
|
||||
<map:parameter name="header" value="xmlui.ArtifactBrowser.RestrictedItem.auth_header"/>
|
||||
<map:parameter name="message" value="xmlui.ArtifactBrowser.RestrictedItem.auth_message"/>
|
||||
</map:transform>
|
||||
<map:serialize type="xml"/>
|
||||
</map:match>
|
||||
</map:match>
|
||||
|
||||
|
||||
</map:match> <!-- End match handle/*/** -->
|
||||
|
||||
<!-- Not a URL we care about, so just pass it on. -->
|
||||
|
@@ -117,9 +117,6 @@
|
||||
<filter-mapping>
|
||||
<filter-name>dspace.request</filter-name>
|
||||
<url-pattern>/*</url-pattern>
|
||||
<dispatcher>REQUEST</dispatcher>
|
||||
<dispatcher>FORWARD</dispatcher>
|
||||
<dispatcher>INCLUDE</dispatcher>
|
||||
</filter-mapping>
|
||||
|
||||
<!--
|
||||
|
@@ -531,7 +531,7 @@
|
||||
<!-- org.dspace.app.xmlui.Submission.submissions -->
|
||||
<message key="xmlui.Submission.Submissions.title">Submissions & Workflow</message>
|
||||
<message key="xmlui.Submission.Submissions.trail">Submissions</message>
|
||||
<message key="xmlui.Submission.Submissions.head">Submissions & workflow tasks</message>
|
||||
<message key="xmlui.Submission.Submissions.head">Submissions & Workflow Tasks</message>
|
||||
<message key="xmlui.Submission.Submissions.untitled"><i>Untitled</i></message>
|
||||
<message key="xmlui.Submission.Submissions.email">email: </message>
|
||||
<!-- Same transformer, workflow section -->
|
||||
|
1
dspace/config/crosswalks/oai/description.xml
Normal file
1
dspace/config/crosswalks/oai/description.xml
Normal file
@@ -0,0 +1 @@
|
||||
<XOAIDescription xmlns="http://www.lyncode.com/XOAIConfiguration">XOAI: OAI-PMH Java Toolkit</XOAIDescription>
|
@@ -5,7 +5,7 @@
|
||||
# faceted-search system. #
|
||||
#---------------------------------------------------------------#
|
||||
##### Search Indexing #####
|
||||
search.server = http://localhost:8080/solr/search
|
||||
search.server = ${solr.server}/search
|
||||
|
||||
#Char used to ensure that the sidebar facets are case insensitive
|
||||
#solr.facets.split.char=\n|||\n
|
||||
|
@@ -18,6 +18,9 @@ bitstream.baseUrl = ${dspace.url}
|
||||
# Base Configuration Directory
|
||||
config.dir = ${dspace.dir}/config/crosswalks/oai
|
||||
|
||||
# Description
|
||||
description.file = ${dspace.dir}/config/crosswalks/oai/description.xml
|
||||
|
||||
# Cache enabled?
|
||||
cache.enabled = true
|
||||
|
||||
|
@@ -138,7 +138,7 @@ auth-type = Basic
|
||||
|
||||
# The location where uploaded files and packages are
|
||||
# stored while being processed
|
||||
upload.tempdir = /dspace/upload
|
||||
upload.tempdir = ${dspace.dir}/upload
|
||||
|
||||
# The metadata field in which to store the updated date for
|
||||
# items deposited via SWORD.
|
||||
|
Binary file not shown.
@@ -17,7 +17,7 @@
|
||||
<parent>
|
||||
<groupId>org.dspace</groupId>
|
||||
<artifactId>modules</artifactId>
|
||||
<version>4.0-SNAPSHOT</version>
|
||||
<version>3.2</version>
|
||||
<relativePath>..</relativePath>
|
||||
</parent>
|
||||
|
||||
|
@@ -12,7 +12,7 @@
|
||||
<parent>
|
||||
<groupId>org.dspace</groupId>
|
||||
<artifactId>modules</artifactId>
|
||||
<version>4.0-SNAPSHOT</version>
|
||||
<version>3.2</version>
|
||||
<relativePath>..</relativePath>
|
||||
</parent>
|
||||
|
||||
|
@@ -13,7 +13,7 @@
|
||||
<parent>
|
||||
<groupId>org.dspace</groupId>
|
||||
<artifactId>modules</artifactId>
|
||||
<version>4.0-SNAPSHOT</version>
|
||||
<version>3.2</version>
|
||||
<relativePath>..</relativePath>
|
||||
</parent>
|
||||
|
||||
|
@@ -12,7 +12,7 @@
|
||||
<parent>
|
||||
<artifactId>modules</artifactId>
|
||||
<groupId>org.dspace</groupId>
|
||||
<version>4.0-SNAPSHOT</version>
|
||||
<version>3.2</version>
|
||||
<relativePath>..</relativePath>
|
||||
</parent>
|
||||
|
||||
|
@@ -9,7 +9,7 @@
|
||||
<parent>
|
||||
<groupId>org.dspace</groupId>
|
||||
<artifactId>dspace-parent</artifactId>
|
||||
<version>4.0-SNAPSHOT</version>
|
||||
<version>3.2</version>
|
||||
<relativePath>../../pom.xml</relativePath>
|
||||
</parent>
|
||||
|
||||
|
@@ -2,7 +2,7 @@
|
||||
<modelVersion>4.0.0</modelVersion>
|
||||
<groupId>org.dspace.modules</groupId>
|
||||
<artifactId>solr</artifactId>
|
||||
<version>4.0-SNAPSHOT</version>
|
||||
<version>3.2</version>
|
||||
<packaging>war</packaging>
|
||||
<name>DSpace SOLR :: Local Customizations</name>
|
||||
<description>
|
||||
@@ -13,7 +13,7 @@
|
||||
<parent>
|
||||
<groupId>org.dspace</groupId>
|
||||
<artifactId>modules</artifactId>
|
||||
<version>4.0-SNAPSHOT</version>
|
||||
<version>3.2</version>
|
||||
<relativePath>..</relativePath>
|
||||
</parent>
|
||||
|
||||
|
@@ -16,7 +16,7 @@
|
||||
<parent>
|
||||
<groupId>org.dspace</groupId>
|
||||
<artifactId>modules</artifactId>
|
||||
<version>4.0-SNAPSHOT</version>
|
||||
<version>3.2</version>
|
||||
<relativePath>..</relativePath>
|
||||
</parent>
|
||||
|
||||
|
@@ -16,7 +16,7 @@
|
||||
<parent>
|
||||
<groupId>org.dspace</groupId>
|
||||
<artifactId>modules</artifactId>
|
||||
<version>4.0-SNAPSHOT</version>
|
||||
<version>3.2</version>
|
||||
<relativePath>..</relativePath>
|
||||
</parent>
|
||||
|
||||
|
@@ -12,7 +12,7 @@
|
||||
<parent>
|
||||
<groupId>org.dspace</groupId>
|
||||
<artifactId>modules</artifactId>
|
||||
<version>4.0-SNAPSHOT</version>
|
||||
<version>3.2</version>
|
||||
<relativePath>..</relativePath>
|
||||
</parent>
|
||||
|
||||
|
@@ -15,7 +15,7 @@
|
||||
<parent>
|
||||
<groupId>org.dspace</groupId>
|
||||
<artifactId>dspace-parent</artifactId>
|
||||
<version>4.0-SNAPSHOT</version>
|
||||
<version>3.2</version>
|
||||
<relativePath>..</relativePath>
|
||||
</parent>
|
||||
|
||||
|
@@ -142,6 +142,7 @@ Common usage:
|
||||
<echo message="load_registries --> Load metadata & file format registries into the " />
|
||||
<echo message=" database" />
|
||||
<echo message="" />
|
||||
<echo message="clean_backups --> Remove .bak directories under install directory" />
|
||||
<echo message="clean_database --> Remove DSpace database tables, destroying data" />
|
||||
<echo message="" />
|
||||
<echo message="" />
|
||||
|
37
pom.xml
37
pom.xml
@@ -4,7 +4,7 @@
|
||||
<groupId>org.dspace</groupId>
|
||||
<artifactId>dspace-parent</artifactId>
|
||||
<packaging>pom</packaging>
|
||||
<version>4.0-SNAPSHOT</version>
|
||||
<version>3.2</version>
|
||||
<name>DSpace Parent Project</name>
|
||||
<url>https://github.com/dspace/DSpace</url>
|
||||
|
||||
@@ -377,7 +377,7 @@
|
||||
</profile>
|
||||
|
||||
<!--
|
||||
Builds LNI WAR for DSpace
|
||||
Builds LNI WAR & Client for DSpace
|
||||
-->
|
||||
<profile>
|
||||
<id>dspace-lni</id>
|
||||
@@ -388,6 +388,7 @@
|
||||
</activation>
|
||||
<modules>
|
||||
<module>dspace-lni</module>
|
||||
<module>dspace-lni/dspace-lni-client</module>
|
||||
</modules>
|
||||
</profile>
|
||||
|
||||
@@ -444,71 +445,71 @@
|
||||
<dependency>
|
||||
<groupId>org.dspace</groupId>
|
||||
<artifactId>dspace-api</artifactId>
|
||||
<version>4.0-SNAPSHOT</version>
|
||||
<version>3.2</version>
|
||||
</dependency>
|
||||
<dependency>
|
||||
<groupId>org.dspace.modules</groupId>
|
||||
<artifactId>additions</artifactId>
|
||||
<version>4.0-SNAPSHOT</version>
|
||||
<version>3.2</version>
|
||||
</dependency>
|
||||
|
||||
<dependency>
|
||||
<groupId>org.dspace</groupId>
|
||||
<artifactId>dspace-sword</artifactId>
|
||||
<version>4.0-SNAPSHOT</version>
|
||||
<version>3.2</version>
|
||||
<type>jar</type>
|
||||
<classifier>classes</classifier>
|
||||
</dependency>
|
||||
<dependency>
|
||||
<groupId>org.dspace</groupId>
|
||||
<artifactId>dspace-sword</artifactId>
|
||||
<version>4.0-SNAPSHOT</version>
|
||||
<version>3.2</version>
|
||||
<type>war</type>
|
||||
</dependency>
|
||||
<dependency>
|
||||
<groupId>org.dspace</groupId>
|
||||
<artifactId>dspace-swordv2</artifactId>
|
||||
<version>4.0-SNAPSHOT</version>
|
||||
<version>3.2</version>
|
||||
<type>jar</type>
|
||||
<classifier>classes</classifier>
|
||||
</dependency>
|
||||
<dependency>
|
||||
<groupId>org.dspace</groupId>
|
||||
<artifactId>dspace-swordv2</artifactId>
|
||||
<version>4.0-SNAPSHOT</version>
|
||||
<version>3.2</version>
|
||||
<type>war</type>
|
||||
</dependency>
|
||||
|
||||
<dependency>
|
||||
<groupId>org.dspace</groupId>
|
||||
<artifactId>dspace-jspui</artifactId>
|
||||
<version>4.0-SNAPSHOT</version>
|
||||
<version>3.2</version>
|
||||
<type>jar</type>
|
||||
<classifier>classes</classifier>
|
||||
</dependency>
|
||||
<dependency>
|
||||
<groupId>org.dspace</groupId>
|
||||
<artifactId>dspace-jspui</artifactId>
|
||||
<version>4.0-SNAPSHOT</version>
|
||||
<version>3.2</version>
|
||||
<type>war</type>
|
||||
</dependency>
|
||||
<dependency>
|
||||
<groupId>org.dspace</groupId>
|
||||
<artifactId>dspace-oai</artifactId>
|
||||
<version>4.0-SNAPSHOT</version>
|
||||
<version>3.2</version>
|
||||
<type>jar</type>
|
||||
<classifier>classes</classifier>
|
||||
</dependency>
|
||||
<dependency>
|
||||
<groupId>org.dspace</groupId>
|
||||
<artifactId>dspace-oai</artifactId>
|
||||
<version>4.0-SNAPSHOT</version>
|
||||
<version>3.2</version>
|
||||
<type>war</type>
|
||||
</dependency>
|
||||
<dependency>
|
||||
<groupId>org.dspace</groupId>
|
||||
<artifactId>dspace-lni</artifactId>
|
||||
<version>4.0-SNAPSHOT</version>
|
||||
<version>3.2</version>
|
||||
<type>jar</type>
|
||||
<classifier>classes</classifier>
|
||||
</dependency>
|
||||
@@ -520,26 +521,26 @@
|
||||
<dependency>
|
||||
<groupId>org.dspace</groupId>
|
||||
<artifactId>dspace-lni</artifactId>
|
||||
<version>4.0-SNAPSHOT</version>
|
||||
<version>3.2</version>
|
||||
<type>war</type>
|
||||
</dependency>
|
||||
<dependency>
|
||||
<groupId>org.dspace</groupId>
|
||||
<artifactId>dspace-xmlui</artifactId>
|
||||
<version>4.0-SNAPSHOT</version>
|
||||
<version>3.2</version>
|
||||
<type>jar</type>
|
||||
<classifier>classes</classifier>
|
||||
</dependency>
|
||||
<dependency>
|
||||
<groupId>org.dspace</groupId>
|
||||
<artifactId>dspace-xmlui</artifactId>
|
||||
<version>4.0-SNAPSHOT</version>
|
||||
<version>3.2</version>
|
||||
<type>war</type>
|
||||
</dependency>
|
||||
<dependency>
|
||||
<groupId>org.dspace</groupId>
|
||||
<artifactId>dspace-services</artifactId>
|
||||
<version>4.0-SNAPSHOT</version>
|
||||
<version>3.2</version>
|
||||
</dependency>
|
||||
<!-- DSpace Localization Packages -->
|
||||
<dependency>
|
||||
@@ -1179,7 +1180,7 @@
|
||||
<connection>scm:git:git@github.com:DSpace/DSpace.git</connection>
|
||||
<developerConnection>scm:git:git@github.com:DSpace/DSpace.git</developerConnection>
|
||||
<url>git@github.com:DSpace/DSpace.git</url>
|
||||
<tag>HEAD</tag>
|
||||
<tag>dspace-3.2</tag>
|
||||
</scm>
|
||||
|
||||
<!--
|
||||
|
Reference in New Issue
Block a user