Tag release 2.0.0

git-svn-id: https://svn.apache.org/repos/asf/ant/ivy/core/tags/2.0.0@735557 13f79535-47bb-0310-9956-ffa450edef68
diff --git a/CHANGES.txt b/CHANGES.txt
index 755231a..2b44597 100644
--- a/CHANGES.txt
+++ b/CHANGES.txt
@@ -83,9 +83,11 @@
 	
    2.0.0
 =====================================
+- IMPROVEMENT: Extend packager resolver to allow arbitrary ant tasks in build instructions (IVY-994) (thanks to Archie Cobbs)
 - IMPROVEMENT: Ivy Standalone setting to overwrite publications (IVY-976)
 - IMPROVEMENT: Support useOrigin for artifacts with a set url attribute (IVY-965) (thanks to alex322)
 
+- FIX: NullPointerException at PomModuleDescriptorBuilder.addDependency (IVY-995)
 - FIX: Log levels aren't respected in certain cases using the standalone functionality (IVY-960) (thanks to Patrick Woodworth)
 - FIX: NPE in LogReportOutputter (IVY-961)
 - FIX: NullPointerException when resolving module wihout revision in the pattern (IVY-980)
diff --git a/README b/README
index 1c4cfef..8caa20b 100644
--- a/README
+++ b/README
@@ -1,5 +1,5 @@
-			Apache Ivy v2.0.0-rc1
-		   ------------------------
+			Apache Ivy v2.0.0
+		   -------------------
 
 Supported Platforms
 --------------------
diff --git a/RELEASE_NOTES b/RELEASE_NOTES
index fea5fdd..ad78430 100644
--- a/RELEASE_NOTES
+++ b/RELEASE_NOTES
@@ -1,4 +1,4 @@
-	                      Apache Ivy v2.0.0-rc1
+	                      Apache Ivy v2.0.0
                                Release Notes
    -----------------------------------------------------------------------
 
@@ -32,16 +32,9 @@
 
 2. Status of this release 
 
-This is the first release candidate of Ivy targetting 2.0.0. 
-As a release candidate version, we strongly encourage the use of this version for 
-testing and validation.
-From now on, features are frozen until final 2.0.0 version, only bug fixes may be 
-applied before 2.0.0.
-If no outstanding bugs are reported with this release candidate, it will promoted 
-to 2.0.0 about two weeks after this release candidate. 
-
-The current production quality version is still 1.4.1, which has not been produced 
-within the Apache Software Foundation.
+This is the first official release made since Ivy has moved to the Apache Software
+Foundation. We strongly encourage the use of this new version instead of the older
+1.4.1 version, which has not been produced within the Apache Software Foundation.
 
 3. Major Changes in this Release
 
@@ -167,20 +160,7 @@
 	Gilles Scokart
 
  Contributors
- 	Carlton Brown
- 	Chris Chilvers
-	Archie Cobbs
-	Ben Hale
-	Tobias Himstedt
-	Michael Kebe
-	Alexey Kiselev
-	Sakari Maaranen
-	David Maplesden
-	Brian Sanders
-	Simon Steiner
-	James P. White
 	Patrick Woodworth
-	Jing Xue
 
 For the list of people who have contributed since Ivy inception, see CHANGES.txt file.
 
@@ -191,133 +171,13 @@
 For details about the following changes, check our JIRA install at 
 http://issues.apache.org/jira/browse/ivy
 
-List of changes since Ivy 2.0.0-beta2:
-- NEW: Report version of Ivy in HTTP headers (user-agent?) when Ivy downloads artifacts (IVY-878)
-- NEW: Add publish support to URL resolver (IVY-848) (thanks to Brian Sanders)
-- NEW: Better support for local builds (IVY-857)
-- NEW: Retain original dependency constraint rules in resolved ivy file (IVY-739)
-- NEW: Add a new resolve mode (optionally per module) to utilize dynamic constraint rule metadata (IVY-740)
-- NEW: Add transitive dependency version and branch override mechanism (IVY-784)
-- NEW: Add new packager resolver (IVY-829) (thanks to Archie Cobbs)
+List of changes since Ivy 2.0.0-rc2:
+- IMPROVEMENT: Ivy Standalone setting to overwrite publications (IVY-976)
+- IMPROVEMENT: Support useOrigin for artifacts with a set url attribute (IVY-965) (thanks to alex322)
 
-- IMPROVEMENT: DualResolver should also provide setDescriptor method instead of setAllownomd, which is deprecated for the other resolvers (IVY-903)
-- IMPROVEMENT: Parse license information in poms (IVY-892)
-- IMPROVEMENT: Change 'alwaysUseExactRevision' default value to false (IVY-891)
-- IMPROVEMENT: Better and more homogeneous relative paths handling (IVY-387) 
-- IMPROVEMENT: undeprecate configure task (IVY-849)
-- IMPROVEMENT: Detect missing artifacts on publish asap (IVY-862)
-- IMPROVEMENT: Allow to set the branch at deliver/publish time (IVY-859)
-- IMPROVEMENT: Add defaultconf in publications tag of ivy file (IVY-801)
-- IMPROVEMENT: Support atomic publish with sub directory structure (IVY-856)
-- IMPROVEMENT: Provide ant task to retrieve information from published ivy modules (IVY-838) (thanks to David Maplesden)
-- IMPROVEMENT: Install task fails but reason is not displayed without using -debug or -verbose (IVY-834)
-- IMPROVEMENT: SSH resolver doesn't support keyboard-interactive authentication (IVY-836) (thanks to Tobias Himstedt)
-- IMPROVEMENT: declare source and javadoc artifacts in maven2 modules (IVY-325)
-- IMPROVEMENT: Set the last modified attribute of files downloaded from repositories (IVY-823)
-- IMPROVEMENT: If DNS is playing up, Ivy takes a lot longer to sort project dependencies (IVY-817)
-- IMPROVEMENT: make it possible to specify permissions of published files for the SSH resolver (IVY-764)
-- IMPROVEMENT: Load Ivy version number into some Ant property (IVY-790)
-- IMPROVEMENT: Make Ivy standalone runnable with no required dependencies (IVY-757)
-- IMPROVEMENT: add branch attribute in ivy:install task (IVY-727)
-- IMPROVEMENT: Parse description information in ivy files (IVY-766)
-- IMPROVEMENT: Parse description and home page from poms (IVY-767)
-- IMPROVEMENT: Change allownomd and skipbuildwithoutivy into a more semantically correct name (IVY-297)
-- IMPROVEMENT: Smarter determination if an expression is exact or not for RegexpPatternMatcher and GlobPatternMatcher
-- IMPROVEMENT: Check branch consistency during resolve (IVY-858)
-- IMPROVEMENT: Give the possibility to not compute ivy.deps.changed (IVY-876)
-- IMPROVEMENT: Add a memory cache for the module descriptor that are parsed from the cache (IVY-883)
-- IMPROVEMENT: Improve performance (IVY-872)
-- IMPROVEMENT: Additional descriptions of build.xml targets (IVY-499)
-
-- FIX: Publish Ant Task 'warnonmissing' ignored (IVY-867)
-- FIX: Ivy stand-alone ignores -cache argument (IVY-901) (thanks to Chris Chilvers)
-- FIX: ivy.cache.dir.${settingsRef} is set to default instead of the defaultCacheDir from the ivysettings.xml after ivy:resolve (IVY-898)
-- FIX: Ivy ibiblio resolver chokes on variables while checking descriptor consistency (IVY-818)
-- FIX: Enable consistent support of the configuration negation operator (IVY-894) (thanks to Patrick Woodworth)
-- FIX: add variable expansion in extra attributes (IVY-798)
-- FIX: Invalid URL when using dynamic ranges (IVY-885)
-- FIX: can't use gotoNode with a node which has not been visited yet (IVY-874)
-- FIX: Ivy Publish Task Fails When XML Comments Exist Next to Dependency Declarations (IVY-888)
-- FIX: Incorrect directory path resolve when running from a different directory (IVY-232)
-- FIX: Ivy#listTokenValues(String, Map) does not filter returned values, and does not use maven-metadata.xml files with IBiblio resolver (IVY-886)
-- FIX: Circular Dependency messages in a resolve do not reflect the configuration used during the resolve (IVY-708)
-- FIX: Failure to transitively install Maven2 artifacts with namespace (IVY-440)
-- FIX: Unwanted eviction of dependencies when optional attributes in dependency and info tags are in consistent (IVY-745)
-- FIX: HTTP Handlers ignore unsuccessful response codes (IVY-864) (thanks to James P. White)
-- FIX: Deliver delivers the wrong version when a dynamic revision is evicted before being resolved (IVY-707)
-- FIX: Inconsistency with "multi-project" tutorial (IVY-667)
-- FIX: URLRepository does not allow some valid file scheme uri's (IVY-884)
-- FIX: Incorrect parsing artifactPattern attribute in a sftp resolver (IVY-661) (thanks to Alexey Kiselev)
-- FIX: Maven2 "ejb" packaging is not supported (IVY-873)
-- FIX: Config files with # in path can't be read (IVY-868) (thanks to Simon Steiner)
-- FIX: Cache can't distinguish artifacts with classifiers (IVY-803) (thanks to James P. White)
-- FIX: Reports showing double dependencies in certain cases (IVY-578)
-- FIX: Dynamic revision resolve does not throw error when configuration is missing (IVY-861)
-- FIX: Referenced resolver not found in macro (IVY-860)
-- FIX: Ivy files are not retrieved when using useOrigin=true (IVY-713)
-- FIX: NPE in Ivy:install task if the repository cache dir has been cleared (IVY-843)
-- FIX: Maven version ranges with ( ) are not supported (IVY-678) (thanks to Michael Kebe)
-- FIX: Ignore maven metadata files when listing revisions (IVY-765)
-- FIX: haltonmissing on publish task does not prevent the other files to be published, even with an atomic publisher (IVY-656)
-- FIX: Transitive dependencies resolves incorrectly when different modules uses the same dependency with different configurations in the same build (IVY-541)
-- FIX: transitive attribute set to false because of dependency (IVY-105)
-- FIX: Wrong check for defaultCacheArtifactPattern (IVY-840)
-- FIX: NPE in ivy:install if ivy.settings.xml contains custom attribute for a module (IVY-838)
-- FIX: Ivy unit tests fail because 'classifier' attribute of 'artifacts' element is missing in ivy.xsd (IVY-837)
-- FIX: Ivy build system: fix build.xml to allow "ant coverage-report" behind a proxy (IVY-832)
-- FIX: NPE in AbstractResolver.exists() if a resource cannot be found (IVY-831)
-- FIX: Ivy distribution jars contains duplicate entries (IVY-828)
-- FIX: ivy:report will generate an HTML file that references non-existent ivy-report.css (IVY-826)
-- FIX: dynamic resolveMode not being dynamic on branch (IVY-825)
-- FIX: Filesystem repositories can not have () in the path (IVY-797)
-- FIX: Type tag in poms not supported (IVY-762)
-- FIX: An empty exclusion tag results in an IllegalArgumentException (IVY-821)
-- FIX: Maven scope defined in POM dependencyManagement section not honoured (IVY-811)
-- FIX: SFTPRepository incorrectly calculates last modified time for resources (IVY-815)
-- FIX: Filesystem resolver does not evaluate [branch] token when publishing (IVY-814)
-- FIX: Using ivy:settings with the "id" attribute not behaving as expected (IVY-809)
-- FIX: onMissingDescriptor doesn't work due to == comparison (IVY-805) (thanks to Ben Hale)
-- FIX: revision token is not set in report outputpattern (IVY-272)
-- FIX: Ivy uses the first set of configurations it sees when resolving multiple versions of a module (IVY-681)
-- FIX: Eviction fails for libs not providing their ivy configuration and providing artifacts named different between lib versions (IVY-537)
-- FIX: Memory leak in ModuleRevisionId.java (IVY-791)
-- FIX: conflict manager scoping does not work as expected (IVY-465)
-- FIX: ivy.original.xml file using artifact pattern in cache and causing problems (IVY-787)
-- FIX: ivy:retrieve with sync="true" removes the .svn directory (IVY-763)
-- FIX: Ivy silently fails XML errors in ivyrep (IVY-579)
-- FIX: Extra Attributes are not available to resolver after resolve if cache was empty (IVY-773)
-- FIX: NullPointerException during ResovleEngine.downloadArtifacts. (IVY-592)
-- FIX: setting m2compatible on ibiblio resolver overwrite root and pattern settings (IVY-437) (thanks to Jing Xue)
-- FIX: unable to resolve snapshot versions (IVY-501)
-- FIX: No error or warning when a resolver references a non-existent cache (IVY-777)
-- FIX: ivy properties defined in an include file not available in the file that includes it (IVY-780)
-- FIX: SFTPRepository.list(String) hides exceptions (IVY-751)
-- FIX: Wrong error message for republishing a module (IVY-752)
-- FIX: resolve fails to put metadata in cache (IVY-779)
-- FIX: multiple cleancache and inline retrieve error (IVY-778)
-- FIX: buildlist evicts modules with the same name, but different organisation (IVY-731)
-- FIX: Out of memory/Stack overflow for new highly coupled project (IVY-595)
-- FIX: Compatibility with maven's dependencyMangement (IVY-753)
-- FIX: ivy:settings fails when override is not set to 'true' (IVY-771)
-- FIX: NPE when specifying both resolveId and inline in an Ivy:Resolve (IVY-776)
-- FIX: repreport task not working against a repository structured by branches (IVY-716)
-- FIX: Ivy reports a conflict when the same file is supposed to be retrieved at the same location twice (or more) (IVY-743)
-- FIX: StackOverflowError when configuration extends itself (IVY-696)
-- FIX: XML schema ambiguity (IVY-750)
-- FIX: ivy-resolve fails when a project has different dependencies in different branches (IVY-717)
-- FIX: PublishEventsTest fails when Ivy sources are located in a directory with a + (IVY-755)
-- FIX: XML entity parsing does not work properly (IVY-737) (thanks to Patrick Woodworth)
-- FIX: Cachefileset task silently fails with parent dir ".." construct (IVY-638)
-- FIX: SFTP should verify input parameter for hostname (IVY-734)
-- FIX: Classpath issues with vfs ftp while being used as a bundle (IVY-785)
-- FIX: Relative include in a settings must be evaluated relatively to the settings file (IVY-372)
-- FIX: The Bundle-Version is 0.0.0 in the build artifacts (IVY-802)
-- FIX: Fix the encoding used in XML reports (IVY-816)
-- FIX: Properties tag in ivy conf do not support relative path (IVY-89)
-- FIX: Ivy causes IveDE to fail where a properties file is relative to ivyconf.xml (IVY-573)
-
-- DOCUMENTATION: Fixed more than a hundred (100+) obsolete "configuration" references; replaced with "settings" (IVY-863) (thanks to Sakari Maaranen)
-- DOCUMENTATION: Elaborated documentation of ivy files and deliver/publish tasks (IVY-847) (thanks to Sakari Maaranen)
-- DOCUMENTATION: Ivy terminology elaboration and illustration (IVY-852) (thanks to Sakari Maaranen)
-- DOCUMENTATION: Broken link in documentation in Ivy files section, info element page (IVY-788)
-- DOCUMENTATION: Add new cache information to resolver doc (IVY-772) (thanks to Carlton Brown)
+- FIX: Log levels aren't respected in certain cases using the standalone functionality (IVY-960) (thanks to Patrick Woodworth)
+- FIX: NPE in LogReportOutputter (IVY-961)
+- FIX: NullPointerException when resolving module wihout revision in the pattern (IVY-980)
+- FIX: IO problem while parsing ivy file (Resetting to invalid mark) (IVY-975)
+- FIX: Cannot parse maven2 poms containing an UTF-8 BOM
+- FIX: Files with non-latin symbols fail to download (IVY-962)
diff --git a/build-release.xml b/build-release.xml
index 36a9f8e..81a77a5 100644
--- a/build-release.xml
+++ b/build-release.xml
@@ -22,9 +22,9 @@
 		xmlns:openpgp="antlib:org.apache.commons.openpgp.ant">
 	<import file="build.xml"/>
 	
-	<taskdef uri="antlib:xooki" file="${doc.src.dir}/xooki/antlib.xml" />
-
 	<target name="generate-doc">
+		<taskdef uri="antlib:xooki" file="${doc.src.dir}/xooki/antlib.xml" />
+
         <copy todir="${doc.build.dir}">
 	        <fileset dir="${doc.src.dir}" includes="images/**,style/**,samples/**,js/**,ivy.xsd" />
         </copy>
@@ -216,13 +216,13 @@
 	
 	<target name="sign" depends="init-ivy">
 		<ivy:settings id="sign.settingsId" file="ivysettings-signtask.xml" />
-		<ivy:cachepath organisation="org.apache.commons" settingsRef="sign.settingsId" transitive="false"
+		<ivy:cachepath organisation="org.apache.commons" settingsRef="sign.settingsId" transitive="false" log="download-only"
 				module="commons-openpgp" revision="1.0-SNAPSHOT" inline="true" pathid="openpgp.classpath"/>
-		<ivy:cachepath organisation="bouncycastle" settingsRef="sign.settingsId"
+		<ivy:cachepath organisation="bouncycastle" settingsRef="sign.settingsId" log="download-only"
 				module="bcprov-jdk16" revision="140" inline="true" pathid="bouncycastle.bcprov.classpath"/>
 		
 		<!-- Didn't find the jdk1.6 bcpg dependency, using the jdk1.5 version instead -->
-		<ivy:cachepath organisation="bouncycastle" settingsRef="sign.settingsId" transitive="false"
+		<ivy:cachepath organisation="bouncycastle" settingsRef="sign.settingsId" transitive="false" log="download-only"
 				module="bcpg-jdk15" revision="140" inline="true" pathid="bouncycastle.bcpg.classpath"/>
 		
 		<property file="${user.home}/ivybuild.properties" />
diff --git a/doc/ivy.xsd b/doc/ivy.xsd
new file mode 100644
index 0000000..383ccc9
--- /dev/null
+++ b/doc/ivy.xsd
@@ -0,0 +1,280 @@
+<?xml version="1.0" encoding="UTF-8"?>

+<!--

+   Licensed to the Apache Software Foundation (ASF) under one

+   or more contributor license agreements.  See the NOTICE file

+   distributed with this work for additional information

+   regarding copyright ownership.  The ASF licenses this file

+   to you under the Apache License, Version 2.0 (the

+   "License"); you may not use this file except in compliance

+   with the License.  You may obtain a copy of the License at

+

+     http://www.apache.org/licenses/LICENSE-2.0

+

+   Unless required by applicable law or agreed to in writing,

+   software distributed under the License is distributed on an

+   "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY

+   KIND, either express or implied.  See the License for the

+   specific language governing permissions and limitations

+   under the License.    

+-->

+<xs:schema xmlns:xs="http://www.w3.org/2001/XMLSchema" elementFormDefault="qualified">

+

+	<xs:complexType name="configurations-conf">

+        <xs:attribute name="name" type="xs:string" use="required"/>

+        <xs:attribute name="transitive" type="xs:boolean"/>

+        <xs:attribute name="extends" type="xs:string"/>

+        <xs:attribute name="description" type="xs:string"/>

+        <xs:attribute name="deprecated" type="xs:string"/>

+        <xs:attribute name="visibility" default="public">

+			<xs:simpleType>

+				<xs:restriction base="xs:string">

+					<xs:enumeration value="private"/>

+					<xs:enumeration value="public"/>

+				</xs:restriction>

+			</xs:simpleType>

+		</xs:attribute>

+        <xs:anyAttribute namespace="##other" processContents="lax" />

+	</xs:complexType>

+

+	<xs:complexType name="global-exclude">

+        <xs:sequence>

+      		<xs:element name="conf" minOccurs="0" maxOccurs="unbounded">

+            	<xs:complexType>

+		            <xs:attribute name="name" type="xs:string" use="required"/>

+            	</xs:complexType>

+      		</xs:element>

+        </xs:sequence>

+        <xs:attribute name="org" type="xs:string"/>

+        <xs:attribute name="module" type="xs:string"/>

+        <xs:attribute name="artifact" type="xs:string"/>

+        <xs:attribute name="type" type="xs:string"/>

+        <xs:attribute name="ext" type="xs:string"/>

+        <xs:attribute name="conf" type="xs:string"/>

+        <xs:attribute name="matcher" type="xs:string"/>

+        <xs:anyAttribute namespace="##other" processContents="lax" />

+	</xs:complexType>

+

+  <xs:element name="ivy-module">

+      <xs:complexType>

+        <xs:sequence>

+  		    <xs:element name="info">

+            	<xs:complexType>

+			        <xs:sequence>

+			      		<xs:element name="license" minOccurs="0" maxOccurs="unbounded">

+			            	<xs:complexType>

+					            <xs:attribute name="name" type="xs:string" use="required"/>

+					            <xs:attribute name="url" type="xs:string"/>

+			            	</xs:complexType>

+			      		</xs:element>

+			      		<xs:element name="ivyauthor" minOccurs="0" maxOccurs="unbounded">

+			            	<xs:complexType>

+					            <xs:attribute name="name" type="xs:string" use="required"/>

+					            <xs:attribute name="url" type="xs:string"/>

+			            	</xs:complexType>

+			      		</xs:element>

+			      		<xs:element name="repository" minOccurs="0" maxOccurs="unbounded">

+			            	<xs:complexType>

+					            <xs:attribute name="name" type="xs:string" use="required"/>

+					            <xs:attribute name="url" type="xs:string"/>

+					            <xs:attribute name="pattern" type="xs:string"/>

+					            <xs:attribute name="ivys" type="xs:boolean"/>

+					            <xs:attribute name="artifacts" type="xs:boolean"/>

+			            	</xs:complexType>

+			      		</xs:element>

+			      		<xs:element name="description" minOccurs="0" maxOccurs="1">

+			            	<xs:complexType mixed="true">

+			            			<xs:sequence>

+			            				<xs:any minOccurs="0" maxOccurs="unbounded" processContents="lax"/>

+					            	</xs:sequence>

+					            <xs:attribute name="homepage" type="xs:string"/>

+			            	</xs:complexType>

+			      		</xs:element>

+			      		<xs:any minOccurs="0" maxOccurs="unbounded" namespace="##other" processContents="lax"/>

+			        </xs:sequence>

+		            <xs:attribute name="organisation" type="xs:string" use="required"/>

+		            <xs:attribute name="module" type="xs:string" use="required"/>

+		            <xs:attribute name="branch" type="xs:string"/>

+		            <xs:attribute name="revision" type="xs:string"/>

+		            <xs:attribute name="status" type="xs:string"/>

+		            <xs:attribute name="publication" type="xs:string"/>

+		            <xs:attribute name="resolver" type="xs:string"/>

+		            <xs:attribute name="namespace" type="xs:string"/>

+		            <xs:attribute name="default" type="xs:boolean"/>

+		            <xs:anyAttribute namespace="##other" processContents="lax" />

+	            </xs:complexType>

+      		</xs:element>

+      		<xs:element name="configurations" minOccurs="0">

+			      <xs:complexType>

+				        <xs:sequence>

+				        	<xs:choice minOccurs="0" maxOccurs="unbounded">

+					      		<xs:element name="conf" type="configurations-conf"/>

+					      		<xs:element name="include">

+					            	<xs:complexType>

+							            <xs:attribute name="file" type="xs:string"/>

+							            <xs:attribute name="url"  type="xs:string"/>

+					            	</xs:complexType>

+					      		</xs:element>

+					      	</xs:choice>

+				        </xs:sequence>

+						<xs:attribute name="defaultconfmapping" type="xs:string"/>				  

+						<xs:attribute name="confmappingoverride" type="xs:boolean" />      

+			      </xs:complexType>

+      		</xs:element>

+      		<xs:element name="publications" minOccurs="0">

+			      <xs:complexType>

+				        <xs:sequence>

+				      		<xs:element name="artifact" minOccurs="0" maxOccurs="unbounded">

+				            	<xs:complexType>

+							        <xs:sequence>

+							      		<xs:element name="conf" minOccurs="0" maxOccurs="unbounded">

+							            	<xs:complexType>

+									            <xs:attribute name="name" type="xs:string" use="required"/>

+							            	</xs:complexType>

+							      		</xs:element>

+							        </xs:sequence>

+						            <xs:attribute name="name" type="xs:string"/>

+						            <xs:attribute name="type" type="xs:string"/>

+						            <xs:attribute name="ext" type="xs:string"/>

+						            <xs:attribute name="conf" type="xs:string"/>

+						            <xs:attribute name="url" type="xs:string"/>

+						            <xs:anyAttribute namespace="##other" processContents="lax" />

+				            	</xs:complexType>

+				      		</xs:element>

+				        </xs:sequence>

+						<xs:attribute name="defaultconf" type="xs:string"/>				  
+			      </xs:complexType>

+      		</xs:element>

+      		<xs:element name="dependencies" minOccurs="0">

+			      <xs:complexType>

+				        <xs:sequence>

+				      		<xs:element name="dependency" minOccurs="0" maxOccurs="unbounded">

+				            	<xs:complexType>

+							        <xs:sequence>

+							      		<xs:element name="conf" minOccurs="0" maxOccurs="unbounded">

+							            	<xs:complexType>

+										        <xs:sequence>

+										      		<xs:element name="mapped" minOccurs="0" maxOccurs="unbounded">

+										            	<xs:complexType>

+												            <xs:attribute name="name" type="xs:string" use="required"/>

+										            	</xs:complexType>

+										      		</xs:element>

+										        </xs:sequence>

+									            <xs:attribute name="name" type="xs:string" use="required"/>

+									            <xs:attribute name="mapped" type="xs:string"/>

+							            	</xs:complexType>

+							      		</xs:element>

+							      		<xs:element name="artifact" minOccurs="0" maxOccurs="unbounded">

+							            	<xs:complexType>

+										        <xs:sequence>

+										      		<xs:element name="conf" minOccurs="0" maxOccurs="unbounded">

+										            	<xs:complexType>

+												            <xs:attribute name="name" type="xs:string" use="required"/>

+										            	</xs:complexType>

+										      		</xs:element>

+										        </xs:sequence>

+									            <xs:attribute name="name" type="xs:string" use="required"/>

+									            <xs:attribute name="type" type="xs:string"/>

+									            <xs:attribute name="ext" type="xs:string"/>

+									            <xs:attribute name="conf" type="xs:string"/>

+									            <xs:attribute name="url" type="xs:string"/>

+									            <xs:anyAttribute namespace="##other" processContents="lax" />

+							            	</xs:complexType>

+							      		</xs:element>

+							      		<xs:element name="include" minOccurs="0" maxOccurs="unbounded">

+							            	<xs:complexType>

+										        <xs:sequence>

+										      		<xs:element name="conf" minOccurs="0" maxOccurs="unbounded">

+										            	<xs:complexType>

+												            <xs:attribute name="name" type="xs:string" use="required"/>

+										            	</xs:complexType>

+										      		</xs:element>

+										        </xs:sequence>

+									            <xs:attribute name="name" type="xs:string"/>

+									            <xs:attribute name="type" type="xs:string"/>

+									            <xs:attribute name="ext" type="xs:string"/>

+									            <xs:attribute name="conf" type="xs:string"/>

+									            <xs:attribute name="matcher" type="xs:string"/>

+									            <xs:anyAttribute namespace="##other" processContents="lax" />

+							            	</xs:complexType>

+							      		</xs:element>

+							      		<xs:element name="exclude" minOccurs="0" maxOccurs="unbounded">

+							            	<xs:complexType>

+										        <xs:sequence>

+										      		<xs:element name="conf" minOccurs="0" maxOccurs="unbounded">

+										            	<xs:complexType>

+												            <xs:attribute name="name" type="xs:string" use="required"/>

+										            	</xs:complexType>

+										      		</xs:element>

+										        </xs:sequence>

+									            <xs:attribute name="org" type="xs:string"/>

+									            <xs:attribute name="module" type="xs:string"/>

+									            <xs:attribute name="name" type="xs:string"/>

+									            <xs:attribute name="type" type="xs:string"/>

+									            <xs:attribute name="ext" type="xs:string"/>

+									            <xs:attribute name="conf" type="xs:string"/>

+									            <xs:attribute name="matcher" type="xs:string"/>

+									            <xs:anyAttribute namespace="##other" processContents="lax" />

+							            	</xs:complexType>

+							      		</xs:element>

+							        </xs:sequence>

+						            <xs:attribute name="org" type="xs:string"/>

+						            <xs:attribute name="name" type="xs:string" use="required"/>

+						            <xs:attribute name="branch" type="xs:string"/>

+						            <xs:attribute name="branchConstraint" type="xs:string"/>
+						            <xs:attribute name="rev" type="xs:string" use="required"/>

+						            <xs:attribute name="revConstraint" type="xs:string"/>

+						            <xs:attribute name="force" type="xs:boolean"/>

+						            <xs:attribute name="changing" type="xs:boolean" default="false"/>

+						            <xs:attribute name="transitive" type="xs:boolean" default="true"/>

+						            <xs:attribute name="conf" type="xs:string"/>

+						            <xs:anyAttribute namespace="##other" processContents="lax" />

+				            	</xs:complexType>

+				      		</xs:element>

+				      		<xs:element name="exclude" type="global-exclude" minOccurs="0" maxOccurs="unbounded" />

+				      		<xs:element name="override" minOccurs="0" maxOccurs="unbounded">

+				            	<xs:complexType>

+						            <xs:attribute name="org" type="xs:string"/>

+						            <xs:attribute name="module" type="xs:string"/>

+						            <xs:attribute name="matcher" type="xs:string"/>

+						            <xs:attribute name="rev" type="xs:string"/>

+						            <xs:attribute name="branch" type="xs:string"/>

+				            	</xs:complexType>

+				      		</xs:element>

+				      		<xs:element name="conflict" minOccurs="0" maxOccurs="unbounded">

+				            	<xs:complexType>

+						            <xs:attribute name="org" type="xs:string"/>

+						            <xs:attribute name="module" type="xs:string"/>

+						            <xs:attribute name="manager" type="xs:string"/>

+						            <xs:attribute name="rev" type="xs:string"/>

+						            <xs:attribute name="matcher" type="xs:string"/>

+						            <xs:anyAttribute namespace="##other" processContents="lax" />

+				            	</xs:complexType>

+				      		</xs:element>

+				        </xs:sequence>

+						<xs:attribute name="defaultconf" type="xs:string"/>				        

+						<xs:attribute name="defaultconfmapping" type="xs:string"/>				        

+                        <xs:attribute name="confmappingoverride" type="xs:boolean" />

+			      </xs:complexType>

+      		</xs:element>

+      		<xs:element name="conflicts" minOccurs="0">

+			      <xs:complexType>

+				        <xs:sequence>

+				      		<xs:element name="manager" maxOccurs="unbounded">

+				            	<xs:complexType>

+						            <xs:attribute name="org" type="xs:string"/>

+						            <xs:attribute name="module" type="xs:string"/>

+						            <xs:attribute name="name" type="xs:string"/>

+						            <xs:attribute name="rev" type="xs:string"/>

+						            <xs:attribute name="matcher" type="xs:string"/>

+						            <xs:anyAttribute namespace="##other" processContents="lax" />

+				            	</xs:complexType>

+				      		</xs:element>

+				        </xs:sequence>

+			      </xs:complexType>

+      		</xs:element>

+        </xs:sequence>

+        <xs:attribute name="version" type="xs:string" use="required"/>

+      </xs:complexType>

+  </xs:element>

+

+</xs:schema>

diff --git a/doc/printTemplate.html b/doc/printTemplate.html
index 3d93bcc..f6e2800 100644
--- a/doc/printTemplate.html
+++ b/doc/printTemplate.html
@@ -20,7 +20,7 @@
 <html xmlns="http://www.w3.org/1999/xhtml" lang="en" xml:lang="en">
 <head>
 	<META HTTP-EQUIV="Content-Type" CONTENT="text/html; charset=ISO-8859-1">
-<title>${title} | Ivy</title>
+<title>${title} | Ivy 2.0.0</title>
 <meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
   <link rel="stylesheet" type="text/css" href="style/print-style.css" />
 </head>
diff --git a/doc/release-notes.html b/doc/release-notes.html
new file mode 100644
index 0000000..67bab7b
--- /dev/null
+++ b/doc/release-notes.html
@@ -0,0 +1,172 @@
+<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01//EN" "http://www.w3.org/TR/html4/strict.dtd">

+<!--

+   Licensed to the Apache Software Foundation (ASF) under one

+   or more contributor license agreements.  See the NOTICE file

+   distributed with this work for additional information

+   regarding copyright ownership.  The ASF licenses this file

+   to you under the Apache License, Version 2.0 (the

+   "License"); you may not use this file except in compliance

+   with the License.  You may obtain a copy of the License at

+

+     http://www.apache.org/licenses/LICENSE-2.0

+

+   Unless required by applicable law or agreed to in writing,

+   software distributed under the License is distributed on an

+   "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY

+   KIND, either express or implied.  See the License for the

+   specific language governing permissions and limitations

+   under the License.    

+-->

+<html>

+<head>

+	<META HTTP-EQUIV="Content-Type" CONTENT="text/html; charset=ISO-8859-1">

+	<script type="text/javascript">var xookiConfig = {level: 0};</script>	

+	<script type="text/javascript" src="xooki/xooki.js"></script>

+</head>

+<body>

+	<textarea id="xooki-source">

+<h2>Apache Ivy 2.0.0 Release Notes</h2>

+

+CONTENTS

+1. What is Apache Ivy?

+2. Status of this release

+3. Major Changes in this Release

+4. Migrating from Jayasoft Ivy to Apache Ivy

+5. How to Get Involved

+6. How to Report Issues

+7. Committers and Contributors for this release

+8. List of Changes in this Release   

+   

+   

+<h3>1. What is Apache Ivy?</h3>

+

+Apache Ivy is a tool for managing (recording, tracking, resolving and reporting) project dependencies. 

+It is characterized by the following:

+

+   1. flexibility and configurability 

+   		Apache Ivy is essentially process agnostic and is not tied to any 

+   		methodology or structure. 

+   		Instead it provides the necessary flexibility and configurability 

+   		to be adapted to a broad range of dependency management and build 

+   		processes.

+   2. tight integration with Apache Ant

+   		while available as a standalone tool, Apache Ivy works particularly well 

+   		with Apache Ant providing a number of powerful Ant tasks ranging 

+   		from dependency resolution to dependency reporting and publication.

+

+<h3>2. Status of this release</h3>

+

+This is the first official release made since Ivy has moved to the Apache Software Foundation. We strongly encourage the use of this new version instead of the older 1.4.1 version, which has not been produced within the Apache Software Foundation.

+

+<h3>3. Major Changes in this Release</h3>

+

+This section describes what has changed between version 1.4.1 and this version of Apache Ivy which may cause incompatibilities. For a full list of detailed changes, please refer to CHANGES.txt file.

+

+This new version of Apache Ivy is almost fully compatible with 1.4 version as long as you do not use custom plugins: Ivy API has changed, but not its behavior. Some tasks and configuration elements have been renamed, but the old versions are still available, they are only deprecated (you will see deprecated warnings). 

+

+<h4>3.1. Java Package Name Changes</h4>

+

+All of the Ivy Java package names have changed in Apache Ivy. They now start with org.apache rather than fr.jayasoft. There have been other changes as well. Important refactorings have done on the source code to ease the understanding of Ivy internal architecture by new developers.

+

+A class named org.apache.ivy.Ivy14 is provided with an API compatible with the fr.jayasoft.Ivy class of Ivy 1.4.1, to ease migration to this new version.

+

+<h4>3.2. Configuration replaced by Settings</h4>

+

+Configuration used to have two meanings in prior Ivy versions, causing some confusion with new users. To avoid this confusion, Apache Ivy calls settings instead of configuration the files used to customize Ivy. Configuration is still used for module configurations.

+

+Besides the changes in the documentation, this renaming also imply a modification in settings files, which now use ivysettings as root element instead of ivyconf, and settings instead of conf element to define top level defaults (such as defaultCache, ...). Previous names have been deprecated, so previous settings files can still be used, but you will see a deprecation warning.

+

+<h4>3.3. Public resolver in default settings is now ibiblio in m2 compatible mode</h4>

+

+In previous versions Ivy used to use the ivyrep resolver as default public resolver, but ivyrep is no longer maintained, while maven 2 repository on ibiblio is growing rapidly.

+

+Since Ivy is compatible with maven 2 repository, defaulting to the ibiblio maven 2 repository makes more sense.

+

+If you have any issue of backward compatibility with these new settings, you can simply set the following ant property before loading the settings (implicitly or explicitly):

+

+<pre>

+ivy.14.compatible=true

+</pre>

+

+<h4>3.4. Relative paths resolution</h4>

+

+Relative paths resolution in Ivy used to be resolved against the current directory. 

+

+In 2.0, relative path resolution is done like this:

+* In an Ivy file, paths are relative to the Ivy file itself (the only possible path in an Ivy file is for configurations declaration inclusion)

+* In settings files, paths for file inclusion (namely properties file loading and settings inclusion) are relative to the directory in which the settings file is located. All other paths must be absolute unless explicitly noted.

+* In Ivy Ant tasks and Ivy parameters or options, paths are relative to Ivy base directory, which when called from Ant is the same as your Ant basedir.

+

+This may break your dependency resolution if you used to use relative paths for configuration file inclusion.

+

+<h4>3.5 Ivyrep ivyroot attribute is now mandatory</h4>

+

+If you still use the ivyrep resolver, you will need to provide an ivyroot. To restore the previous behavior, use ivyroot="http://ivyrep.jayasoft.org/". Since Ivyrep is not maintained anymore, we recommend moving away from this repository anyway.

+

+<h4>3.6 alwaysCheckExactRevision now defaults to false</h4>

+

+This property common to many resolvers is used to tell the resolver if the raw revision should be tested even when the revision is dynamic. This is used in very few use cases, so we decided to change the default to false.

+

+If you want to set the default to true, set 'ivy.default.always.check.exact.revision' to 'true' before loading Ivy settings.

+

+<h3>4. Migrating from Jayasoft Ivy to Apache Ivy</h3>

+

+Besides what is stated in "3. Major Changes in this Release" Apache Ivy is fully compatible with Jayasoft Ivy as long as you do not use custom plugins. This means that you can use Apache Ivy as a drop in replacement of Jayasoft Ivy

+in most cases.

+

+However due to the the renaming of configuration files to settings files, we strongly suggest to update your configuration files:

+- rename the files called ivyconf*.xml in ivysettings*.xml

+- rename 'ivyconf' element in 'ivysettings'

+- rename 'conf' element of those settings file in 'settings'

+

+We also suggest using the new org.apache.ivy.ant package name for the antlib declaration.

+

+Migrating custom plugins can be done by using the org.apache.ivy.Ivy14 class instead of fr.jayasoft.ivy.Ivy, and reorganizing your imports to reflect the changes in the package names.

+

+<h3>5. How to Get Involved</h3>

+

+The Apache Ivy project really needs and appreciates any contributions, including documentation help, source code and feedback.  If you are interested in contributing, please visit http://ant.apache.org/ivy/get-involved.html.

+

+<h3>6. How to Report Issues</h3>

+

+The Apache Ivy project uses JIRA for issue tracking.  Please report any issues you find at http://issues.apache.org/jira/browse/IVY

+

+<h3>7. Committers and Contributors for this Release</h3>

+

+Here is the list of people who have contributed source code and documentation to this release. Many thanks to all of them, and also to the whole Ivy community contributing ideas and feedback, and promoting the use of Ivy. The list would be too long, but Ivy couldn't be what it is without you!

+

+

+ Committers

+	Maarten Coene

+	Xavier Hanin

+	Nicolas Lalevee

+	Gilles Scokart

+

+ Contributors

+    Archie Cobbs

+	Patrick Woodworth

+

+For the list of people who have contributed since Ivy inception, see CHANGES.txt file.

+

+<h3>8. List of Changes in this Release</h3>

+

+For a full release history of Ivy see the file CHANGES.txt

+

+For details about the following changes, check our JIRA install at http://issues.apache.org/jira/browse/ivy

+

+List of changes since Ivy 2.0.0-rc2:

+- IMPROVEMENT: Extend packager resolver to allow arbitrary ant tasks in build instructions (IVY-994) (thanks to Archie Cobbs)

+- IMPROVEMENT: Ivy Standalone setting to overwrite publications (IVY-976)

+- IMPROVEMENT: Support useOrigin for artifacts with a set url attribute (IVY-965) (thanks to alex322)

+

+- FIX: NullPointerException at PomModuleDescriptorBuilder.addDependency (IVY-995)

+- FIX: Log levels aren't respected in certain cases using the standalone functionality (IVY-960) (thanks to Patrick Woodworth)

+- FIX: NPE in LogReportOutputter (IVY-961)

+- FIX: NullPointerException when resolving module wihout revision in the pattern (IVY-980)

+- FIX: IO problem while parsing ivy file (Resetting to invalid mark) (IVY-975)

+- FIX: Cannot parse maven2 poms containing an UTF-8 BOM

+- FIX: Files with non-latin symbols fail to download (IVY-962)

+</textarea>

+<script type="text/javascript">xooki.postProcess();</script>

+</body>

+</html>

diff --git a/doc/resolver/packager.html b/doc/resolver/packager.html
index f24eb3a..e8a4cbf 100644
--- a/doc/resolver/packager.html
+++ b/doc/resolver/packager.html
@@ -40,10 +40,6 @@
 </p>
 
 <p>
-The only packaging operations currently supported are downloading files, extracting files from archives, packaging files into archives, and moving and copying files. In the future more general operations may be supported, once appropriate security controls are in place.
-</p>
-
-<p>
 Packager repositories allow the creation of Ivy repositories that require neither the participation of any of the modules' creators nor setting up a huge mirror site. One such repository on the web is <a href="http://ivyroundup.googlecode.com/">Ivy RoundUp</a>. Of course, private packager repositories are feasible as well.
 </p>
 
@@ -52,11 +48,11 @@
 </p>
 
 <p>
-The packaging instructions are contained in "packager.xml" in a simple XML format. At resolve time this file gets converted into a "build.xml" file via XSLT and then executed using <a href="http://ant.apache.org/">ant</a>. Therefore, ant must be available as an executable on the platform. The ant task executes in a separate process and so is not affected by properties, etc. that may be set in any existing ant environment in which Ivy is running. However, Ivy will define a few properties for convenience; see the "Properties" listed below.
+The packaging instructions are contained in "packager.xml" in a simple XML format. At resolve time this file gets converted into a "build.xml" file via XSLT and then executed using <a href="http://ant.apache.org/">ant</a>. Therefore, ant must be available as an executable on the platform. The ant task executes in a separate ant project and so is not affected by properties, etc. that may be set in any existing ant environment in which Ivy is running. However, Ivy will define a few properties for convenience; see the "Properties" listed below.
 </p>
 
 <p>
-For security reasons, the XSLT transform ensures that (a) all downloaded archives have verified SHA1 checksums (including cached resources); and (b) only a very limited set of ant tasks can be performed during the artifact "build" phase; currently these include move, copy, mkdir, zip, unzip, tar, and untar.
+For security reasons, the XSLT transform ensures that (a) all downloaded archives have verified SHA1 checksums (including cached resources); and (b) only a very limited set of ant tasks can be performed during the artifact "build" phase; currently these include move, copy, mkdir, zip, unzip, tar, and untar (this restriction may be overridden however; see below).
 </p>
 
 <p>
@@ -64,11 +60,11 @@
 </p>
 
 <p>
-Because the downloading and packaging process is relatively slow, it is important to use <a href="../concept.html#cache">Ivy's caching support</a> to avoid repeated execution of the packaging instructions.
+Because the packaging process is relatively slow, it is important to use <a href="../concept.html#cache">Ivy's caching support</a> to avoid repeated execution of the packaging instructions.
 </p>
 
 <h1>Attributes</h1>
-This resolver shares the <a href="../settings/resolvers.html#common">common attributes</a> of standard resolvers.
+This resolver shares the <a href="../settings/resolvers.html#common">common attributes</a> of standard resolvers, plus the following:
 <table class="ivy-attributes">
 <thead>
     <tr><th class="ivy-att">Attribute</th><th class="ivy-att-desc">Description</th><th class="ivy-att-req">Required</th></tr>
@@ -90,6 +86,11 @@
     <td>No; defaults to none</td>
   </tr>
   <tr>
+    <td>restricted</td>
+    <td>True if this resolver should only allow "safe" ant tasks in the packaging instructions. <strong>Warning:</strong> setting <span class="ivy-att">restricted</span> to false creates a security problem due to ant tasks like delete, exec, etc. Do not use this setting when your configuration points to an untrusted repository.</td>
+    <td>No; defaults to true</td>
+  </tr>
+  <tr>
     <td>verbose</td>
     <td>True to run ant with the -verbose flag</td>
     <td>No; defaults to false</td>
@@ -255,11 +256,17 @@
   </tr>
   <tr>
     <td>build</td>
-    <td>Specify move, copy, and/or archiving ant tasks that ultimately result in each artifact being placed into artifacts/[type]s/[artifact].[ext]</td>
+    <td>Specify ant tasks that ultimately result in each artifact being placed into artifacts/[type]s/[artifact].[ext]</td>
     <td>0..1</td>
   </tr>
 </tbody>
 </table>
+<br />
+Which ant tasks are allowed within the build tag is controlled by the <span class="ivy-att">restricted</span> configuration attribute. When true (the default), only the following ant tasks are allowed: copy, jar, mkdir, move, tar, unjar, untar, unwar, unzip, war, and zip. When false, all ant tasks are allowed.
+
+<p>
+<strong>Warning:</strong> setting <span class="ivy-att">restricted</span> to false creates a security problem due to ant tasks like delete, exec, etc. Do not use this setting when your configuration points to an untrusted repository.
+</p>
 
 <h1>Resource XML Elements</h1>
 The resource XML tag supports the following attributes:
diff --git a/doc/template.html b/doc/template.html
index b77a86a..e06ce55 100644
--- a/doc/template.html
+++ b/doc/template.html
@@ -20,7 +20,7 @@
 <html xmlns="http://www.w3.org/1999/xhtml" lang="en" xml:lang="en">
 <head>
 	<META HTTP-EQUIV="Content-Type" CONTENT="text/html; charset=ISO-8859-1">
-<title>${title} | Ivy Documentation</title>
+<title>${title} | Ivy 2.0.0 Documentation</title>
 <meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
   <link rel="stylesheet" type="text/css" href="style/style.css" />
   <script src="js/jquery.pack.js" type="text/javascript"></script>
diff --git a/doc/toc.json b/doc/toc.json
index f457b6e..354ed7a 100644
--- a/doc/toc.json
+++ b/doc/toc.json
@@ -5,6 +5,13 @@
         "title":"Documentation",
         "children": [
             {
+              "id":"release-notes",
+              "title":"Release Notes",
+              "children": [
+
+                ]
+            },
+            {
               "id":"tutorial",
               "title":"Tutorials",
               "children": [
diff --git a/doc/use/cachepath.html b/doc/use/cachepath.html
index ac0d9f4..9f739bb 100644
--- a/doc/use/cachepath.html
+++ b/doc/use/cachepath.html
@@ -29,7 +29,7 @@
 
 This is a [[ant:postresolvetask post resolve task]], with all the behaviour and attributes common to all post resolve tasks.
 
-Please prefer the use of retrieve + standard ant path creation, which make your build more independent from ivy (once artifacts are properly retrieved, ivy is not required any more).
+If you want to make your build more independent from Ivy, you could consider using the [[ant:retrieve retrieve task]]. Once the artifacts are properly retrieved, you can use standard Ant path creation which makes Ivy not necessary any more.
 
 Built path is registered in ant with a given id, and can thus be used like any other ant path using refid.
   
diff --git a/src/java/org/apache/ivy/plugins/parser/m2/PomModuleDescriptorBuilder.java b/src/java/org/apache/ivy/plugins/parser/m2/PomModuleDescriptorBuilder.java
index c3f276e..8532a30 100644
--- a/src/java/org/apache/ivy/plugins/parser/m2/PomModuleDescriptorBuilder.java
+++ b/src/java/org/apache/ivy/plugins/parser/m2/PomModuleDescriptorBuilder.java
@@ -17,7 +17,6 @@
  */
 package org.apache.ivy.plugins.parser.m2;
 
-import java.text.ParseException;
 import java.util.ArrayList;
 import java.util.Arrays;
 import java.util.Collection;
@@ -270,14 +269,11 @@
         ivyModuleDescriptor.addArtifact("master", mainArtifact);
     }
 
-
-    public void addDependency(Resource res, PomDependencyData dep) throws ParseException {
+    public void addDependency(Resource res, PomDependencyData dep) {
         String scope = dep.getScope();
         if ((scope != null) && (scope.length() > 0) && !MAVEN2_CONF_MAPPING.containsKey(scope)) {
-            String msg = "Unknown scope '" + scope + "' for dependency "
-                    + ModuleId.newInstance(dep.getGroupId(), dep.getArtifactId()) + " in "
-                    + res.getName();
-            throw new ParseException(msg, 0);
+            // unknown scope, defaulting to 'compile'
+            scope = "compile";
         }
         
         String version = dep.getVersion();
@@ -408,7 +404,7 @@
     private String getDefaultScope(PomDependencyData dep) {
         String key = getDependencyMgtExtraInfoKeyForScope(dep.getGroupId(), dep.getArtifactId());
         String result = (String) ivyModuleDescriptor.getExtraInfo().get(key);
-        if (result == null) {
+        if ((result == null) || !MAVEN2_CONF_MAPPING.containsKey(result)) {
             result = "compile";
         }
         return result;
diff --git a/src/java/org/apache/ivy/plugins/resolver/packager/PackagerCacheEntry.java b/src/java/org/apache/ivy/plugins/resolver/packager/PackagerCacheEntry.java
index 2a3acc8..129afab 100644
--- a/src/java/org/apache/ivy/plugins/resolver/packager/PackagerCacheEntry.java
+++ b/src/java/org/apache/ivy/plugins/resolver/packager/PackagerCacheEntry.java
@@ -48,6 +48,7 @@
     private final String resourceURL;
     private final boolean validate;
     private final boolean preserve;
+    private final boolean restricted;
     private final boolean verbose;
     private final boolean quiet;
 
@@ -56,13 +57,14 @@
     // CheckStyle:ParameterNumber OFF
     public PackagerCacheEntry(ModuleRevisionId mr, File rootDir,
       File resourceCache, String resourceURL, boolean validate,
-      boolean preserve, boolean verbose, boolean quiet) {
+      boolean preserve, boolean restricted, boolean verbose, boolean quiet) {
         this.mr = mr;
         this.dir = getSubdir(rootDir, this.mr);
         this.resourceCache = resourceCache;
         this.resourceURL = resourceURL;
         this.validate = validate;
         this.preserve = preserve;
+        this.restricted = restricted;
         this.verbose = verbose;
         this.quiet = quiet;
     }
@@ -143,6 +145,7 @@
         if (this.validate) {
             project.setUserProperty("ivy.packager.validate", "true");
         }
+        project.setUserProperty("ivy.packager.restricted", "" + this.restricted);
         if (properties != null) {
             for (Iterator it = properties.entrySet().iterator(); it.hasNext();) {
                 Entry entry = (Entry) it.next();
diff --git a/src/java/org/apache/ivy/plugins/resolver/packager/PackagerResolver.java b/src/java/org/apache/ivy/plugins/resolver/packager/PackagerResolver.java
index 3e90c32..643dda6 100644
--- a/src/java/org/apache/ivy/plugins/resolver/packager/PackagerResolver.java
+++ b/src/java/org/apache/ivy/plugins/resolver/packager/PackagerResolver.java
@@ -57,6 +57,7 @@
     
     private boolean validate = true;
     private boolean preserve;
+    private boolean restricted = true;
     private boolean verbose;
     private boolean quiet;
     
@@ -134,6 +135,13 @@
     }
 
     /**
+     * Set whether to enable restricted mode. Default is true.
+     */
+    public void setRestricted(boolean restricted) {
+        this.restricted = restricted;
+    }
+
+    /**
      * Set whether to run ant with the -verbose flag. Default is false.
      */
     public void setVerbose(boolean verbose) {
@@ -216,7 +224,8 @@
                 return null;
             }
             entry = new PackagerCacheEntry(mr, this.buildRoot, this.resourceCache,
-              this.resourceURL, this.validate, this.preserve, this.verbose, this.quiet);
+              this.resourceURL, this.validate, this.preserve, this.restricted,
+              this.verbose, this.quiet);
             try {
                 entry.build(packager.getResource(), properties);
             } catch (IOException e) {
diff --git a/src/java/org/apache/ivy/plugins/resolver/packager/build.xml b/src/java/org/apache/ivy/plugins/resolver/packager/build.xml
index a43067e..7d00210 100644
--- a/src/java/org/apache/ivy/plugins/resolver/packager/build.xml
+++ b/src/java/org/apache/ivy/plugins/resolver/packager/build.xml
@@ -44,6 +44,7 @@
     <target name="style">
         <xslt style="packager.xsl" in="packager.xml" out="packager-output.xml">
             <param name="resourceURL" expression="${resourceURL}"/>
+            <param name="restricted" expression="${ivy.packager.restricted}"/>
         </xslt>
     </target>
 
diff --git a/src/java/org/apache/ivy/plugins/resolver/packager/packager.xsl b/src/java/org/apache/ivy/plugins/resolver/packager/packager.xsl
index 9084765..286750b 100644
--- a/src/java/org/apache/ivy/plugins/resolver/packager/packager.xsl
+++ b/src/java/org/apache/ivy/plugins/resolver/packager/packager.xsl
@@ -20,6 +20,7 @@
     <xsl:output encoding="UTF-8" method="xml" indent="yes" media-type="text/xml"/>
 
     <xsl:param name="resourceURL"/>
+    <xsl:param name="restricted"/>
 
     <xsl:variable name="maven2repo" select="'http://repo1.maven.org/maven2/'"/>
 
@@ -59,18 +60,30 @@
         <xsl:copy-of select="."/>
     </xsl:template>
 
-    <!-- The allowed build actions -->
-    <xsl:template match="/packager-module/build/copy"><xsl:copy-of select="."/></xsl:template>
-    <xsl:template match="/packager-module/build/jar"><xsl:copy-of select="."/></xsl:template>
-    <xsl:template match="/packager-module/build/mkdir"><xsl:copy-of select="."/></xsl:template>
-    <xsl:template match="/packager-module/build/move"><xsl:copy-of select="."/></xsl:template>
-    <xsl:template match="/packager-module/build/tar"><xsl:copy-of select="."/></xsl:template>
-    <xsl:template match="/packager-module/build/unjar"><xsl:copy-of select="."/></xsl:template>
-    <xsl:template match="/packager-module/build/untar"><xsl:copy-of select="."/></xsl:template>
-    <xsl:template match="/packager-module/build/unwar"><xsl:copy-of select="."/></xsl:template>
-    <xsl:template match="/packager-module/build/unzip"><xsl:copy-of select="."/></xsl:template>
-    <xsl:template match="/packager-module/build/war"><xsl:copy-of select="."/></xsl:template>
-    <xsl:template match="/packager-module/build/zip"><xsl:copy-of select="."/></xsl:template>
+    <!-- The allowed build actions in restricted mode -->
+    <xsl:template match="/packager-module/build/copy" priority="1"><xsl:copy-of select="."/></xsl:template>
+    <xsl:template match="/packager-module/build/jar" priority="1"><xsl:copy-of select="."/></xsl:template>
+    <xsl:template match="/packager-module/build/mkdir" priority="1"><xsl:copy-of select="."/></xsl:template>
+    <xsl:template match="/packager-module/build/move" priority="1"><xsl:copy-of select="."/></xsl:template>
+    <xsl:template match="/packager-module/build/tar" priority="1"><xsl:copy-of select="."/></xsl:template>
+    <xsl:template match="/packager-module/build/unjar" priority="1"><xsl:copy-of select="."/></xsl:template>
+    <xsl:template match="/packager-module/build/untar" priority="1"><xsl:copy-of select="."/></xsl:template>
+    <xsl:template match="/packager-module/build/unwar" priority="1"><xsl:copy-of select="."/></xsl:template>
+    <xsl:template match="/packager-module/build/unzip" priority="1"><xsl:copy-of select="."/></xsl:template>
+    <xsl:template match="/packager-module/build/war" priority="1"><xsl:copy-of select="."/></xsl:template>
+    <xsl:template match="/packager-module/build/zip" priority="1"><xsl:copy-of select="."/></xsl:template>
+
+    <!-- Allow other build actions when restricted="false", otherwise generate error -->
+    <xsl:template match="/packager-module/build/*">
+        <xsl:choose>
+            <xsl:when test="$restricted = 'false'">
+                <xsl:copy-of select="."/>
+            </xsl:when>
+            <xsl:otherwise>
+                <xsl:message terminate="yes">build tag &lt;<xsl:value-of select="name()"/>&gt; not allowed in restricted mode</xsl:message>
+            </xsl:otherwise>
+        </xsl:choose>
+    </xsl:template>
 
     <!-- Resource definitions -->
     <xsl:template match="/packager-module/resource">
diff --git a/version.properties b/version.properties
index 8dc30c4..08c0fb9 100644
--- a/version.properties
+++ b/version.properties
@@ -16,5 +16,5 @@
 #	 * specific language governing permissions and limitations
 #	 * under the License.
 #	 ***************************************************************
-target.ivy.version=2.0.x
-target.ivy.bundle.version=2.0.x
+target.ivy.version=2.0.0
+target.ivy.bundle.version=2.0.0.final