Blob Blame History Raw
diff -uNr josm-0-3376-original/build.xml josm-0/build.xml
--- josm-0-3376-original/build.xml	2010-05-08 17:44:45.000000000 +0200
+++ josm-0/build.xml	2010-07-21 23:00:18.483143707 +0200
@@ -99,7 +99,6 @@
 
 			<!-- All jar files necessary to run only JOSM (no tests) -->
 			<zipfileset src="lib/metadata-extractor-2.3.1-nosun.jar" />
-			<zipfileset src="lib/signpost-core-1.1.jar" />
 		</jar>
 	</target>
 
@@ -119,7 +118,8 @@
 
 	<target name="compile" depends="init">
 		<javac srcdir="src" classpathref="classpath" destdir="build"
-				target="1.5" source="1.5" debug="on" encoding="UTF-8">
+				target="1.5" source="1.5" debug="on" encoding="UTF-8"
+                                excludes="org/openstreetmap/josm/gui/oauth/,org/openstreetmap/josm/data/oauth/">
 			<compilerarg value="-Xlint:deprecation"/>
 			<compilerarg value="-Xlint:unchecked"/>
 		</javac>
diff -uNr josm-0-3376-original/src/org/openstreetmap/josm/gui/ExceptionDialogUtil.java josm-0/src/org/openstreetmap/josm/gui/ExceptionDialogUtil.java
--- josm-0-3376-original/src/org/openstreetmap/josm/gui/ExceptionDialogUtil.java	2010-05-15 21:57:19.000000000 +0200
+++ josm-0/src/org/openstreetmap/josm/gui/ExceptionDialogUtil.java	2010-07-21 23:00:18.484143506 +0200
@@ -15,7 +15,7 @@
 import org.openstreetmap.josm.Main;
 import org.openstreetmap.josm.io.ChangesetClosedException;
 import org.openstreetmap.josm.io.IllegalDataException;
-import org.openstreetmap.josm.io.MissingOAuthAccessTokenException;
+//import org.openstreetmap.josm.io.MissingOAuthAccessTokenException;
 import org.openstreetmap.josm.io.OsmApiException;
 import org.openstreetmap.josm.io.OsmApiInitializationException;
 import org.openstreetmap.josm.io.OsmTransferException;
@@ -249,11 +249,13 @@
     public static void explainAuthenticationFailed(OsmApiException e) {
         String authMethod = Main.pref.get("osm-server.auth-method", "basic");
         String msg;
+        /*
         if (authMethod.equals("oauth")) {
             msg = ExceptionUtil.explainFailedOAuthAuthentication(e);
         } else {
+        */
             msg = ExceptionUtil.explainFailedBasicAuthentication(e);
-        }
+        //}
 
         HelpAwareOptionPane.showOptionDialog(
                 Main.parent,
@@ -273,7 +275,7 @@
     public static void explainAuthorizationFailed(OsmApiException e) {
         HelpAwareOptionPane.showOptionDialog(
                 Main.parent,
-                ExceptionUtil.explainFailedOAuthAuthorisation(e),
+                tr("OAuth authorization disabled by Fedora."),
                 tr("Authorisation Failed"),
                 JOptionPane.ERROR_MESSAGE,
                 ht("/ErrorMessages#AuthenticationFailed")
@@ -318,7 +320,7 @@
      *
      * @param e the exception
      */
-    public static void explainMissingOAuthAccessTokenException(MissingOAuthAccessTokenException e) {
+/*    public static void explainMissingOAuthAccessTokenException(MissingOAuthAccessTokenException e) {
         HelpAwareOptionPane.showOptionDialog(
                 Main.parent,
                 ExceptionUtil.explainMissingOAuthAccessTokenException(e),
@@ -327,6 +329,7 @@
                 ht("/ErrorMessages#MissingOAuthAccessToken")
         );
     }
+*/    
 
     /**
      * Explains a {@see UnknownHostException} which has caused an {@see OsmTransferException}.
@@ -404,10 +407,10 @@
             return;
         }
 
-        if (e instanceof MissingOAuthAccessTokenException) {
+/*        if (e instanceof MissingOAuthAccessTokenException) {
             explainMissingOAuthAccessTokenException((MissingOAuthAccessTokenException)e);
             return;
-        }
+        }*/
 
         if (e instanceof OsmApiException) {
             OsmApiException oae = (OsmApiException) e;
diff -uNr josm-0-3376-original/src/org/openstreetmap/josm/gui/MainApplication.java josm-0/src/org/openstreetmap/josm/gui/MainApplication.java
--- josm-0-3376-original/src/org/openstreetmap/josm/gui/MainApplication.java	2010-05-30 17:07:19.000000000 +0200
+++ josm-0/src/org/openstreetmap/josm/gui/MainApplication.java	2010-07-21 23:00:18.485143471 +0200
@@ -24,7 +24,7 @@
 import javax.swing.JFrame;
 
 import org.openstreetmap.josm.Main;
-import org.openstreetmap.josm.gui.preferences.server.OAuthAccessTokenHolder;
+//import org.openstreetmap.josm.gui.preferences.server.OAuthAccessTokenHolder;
 import org.openstreetmap.josm.gui.progress.ProgressMonitor;
 import org.openstreetmap.josm.io.DefaultProxySelector;
 import org.openstreetmap.josm.io.auth.CredentialsManagerFactory;
@@ -177,7 +177,7 @@
         DefaultAuthenticator.createInstance(CredentialsManagerFactory.getCredentialManager());
         Authenticator.setDefault(DefaultAuthenticator.getInstance());
         ProxySelector.setDefault(new DefaultProxySelector(ProxySelector.getDefault()));
-        OAuthAccessTokenHolder.getInstance().init(Main.pref, CredentialsManagerFactory.getCredentialManager());
+//        OAuthAccessTokenHolder.getInstance().init(Main.pref, CredentialsManagerFactory.getCredentialManager());
 
         // asking for help? show help and exit
         if (args.containsKey("help")) {
diff -uNr josm-0-3376-original/src/org/openstreetmap/josm/gui/preferences/server/AuthenticationPreferencesPanel.java josm-0/src/org/openstreetmap/josm/gui/preferences/server/AuthenticationPreferencesPanel.java
--- josm-0-3376-original/src/org/openstreetmap/josm/gui/preferences/server/AuthenticationPreferencesPanel.java	2010-03-05 10:54:39.000000000 +0100
+++ josm-0/src/org/openstreetmap/josm/gui/preferences/server/AuthenticationPreferencesPanel.java	2010-07-21 23:00:18.485143471 +0200
@@ -39,7 +39,7 @@
     /** the panel for the basic authentication parameters */
     private BasicAuthenticationPreferencesPanel pnlBasicAuthPreferences;
     /** the panel for the OAuth authentication parameters */
-    private OAuthAuthenticationPreferencesPanel pnlOAuthPreferences;
+//    private OAuthAuthenticationPreferencesPanel pnlOAuthPreferences;
 
     /**
      * builds the UI
@@ -66,6 +66,7 @@
         add(rbOAuth = new JRadioButton(), gc);
         rbOAuth.setText(tr("Use OAuth"));
         rbOAuth.setToolTipText(tr("Select to use OAuth as authentication mechanism"));
+        rbOAuth.setEnabled(false);
         rbOAuth.addItemListener(authChangeListener);
 
         //-- radio button for OAuth
@@ -85,7 +86,7 @@
 
         //-- the two panel for authentication parameters
         pnlBasicAuthPreferences = new BasicAuthenticationPreferencesPanel();
-        pnlOAuthPreferences = new OAuthAuthenticationPreferencesPanel();
+//        pnlOAuthPreferences = new OAuthAuthenticationPreferencesPanel();
 
         rbBasicAuthentication.setSelected(true);
         pnlAuthenticationParameteters.add(pnlBasicAuthPreferences, BorderLayout.CENTER);
@@ -107,7 +108,7 @@
             rbBasicAuthentication.setSelected(true);
         }
         pnlBasicAuthPreferences.initFromPreferences();
-        pnlOAuthPreferences.initFromPreferences();
+//        pnlOAuthPreferences.initFromPreferences();
     }
 
     public void saveToPreferences() {
@@ -122,6 +123,7 @@
         if (authMethod.equals("basic")) {
             // save username and password and clear the OAuth token
             pnlBasicAuthPreferences.saveToPreferences();
+/*            
             OAuthAccessTokenHolder.getInstance().clear();
             OAuthAccessTokenHolder.getInstance().save(Main.pref, CredentialsManagerFactory.getCredentialManager());
         } else if (authMethod.equals("oauth")) {
@@ -129,6 +131,7 @@
             pnlBasicAuthPreferences.clearPassword();
             pnlBasicAuthPreferences.saveToPreferences();
             pnlOAuthPreferences.saveToPreferences();
+*/            
         }
     }
 
@@ -141,18 +144,21 @@
                 pnlAuthenticationParameteters.removeAll();
                 pnlAuthenticationParameteters.add(pnlBasicAuthPreferences, BorderLayout.CENTER);
                 pnlBasicAuthPreferences.revalidate();
-            } else {
+/*            } else {
                 pnlAuthenticationParameteters.removeAll();
                 pnlAuthenticationParameteters.add(pnlOAuthPreferences, BorderLayout.CENTER);
                 pnlOAuthPreferences.revalidate();
+*/                
             }
             repaint();
         }
     }
 
     public void propertyChange(PropertyChangeEvent evt) {
+/*
         if (pnlOAuthPreferences != null) {
             pnlOAuthPreferences.propertyChange(evt);
         }
+*/        
     }
 }
diff -uNr josm-0-3376-original/src/org/openstreetmap/josm/gui/preferences/server/OAuthAccessTokenHolder.java josm-0/src/org/openstreetmap/josm/gui/preferences/server/OAuthAccessTokenHolder.java
--- josm-0-3376-original/src/org/openstreetmap/josm/gui/preferences/server/OAuthAccessTokenHolder.java	2010-03-05 10:54:39.000000000 +0100
+++ josm-0/src/org/openstreetmap/josm/gui/preferences/server/OAuthAccessTokenHolder.java	2010-07-21 23:00:18.486143466 +0200
@@ -6,7 +6,7 @@
 import java.util.logging.Logger;
 
 import org.openstreetmap.josm.data.Preferences;
-import org.openstreetmap.josm.data.oauth.OAuthToken;
+//import org.openstreetmap.josm.data.oauth.OAuthToken;
 import org.openstreetmap.josm.io.auth.CredentialsManager;
 import org.openstreetmap.josm.io.auth.CredentialsManagerException;
 import org.openstreetmap.josm.tools.CheckParameterUtil;
@@ -90,11 +90,13 @@
         this.accessTokenSecret = accessTokenSecret;
     }
 
+/*
     public OAuthToken getAccessToken() {
         if (!containsAccessToken())
             return null;
         return new OAuthToken(accessTokenKey, accessTokenSecret);
     }
+*/
 
     /**
      * Sets the access token hold by this holder.
@@ -112,6 +114,7 @@
      * 
      * @param token the access token. Can be null to clear the content in this holder.
      */
+/*
     public void setAccessToken(OAuthToken token) {
         if (token == null) {
             this.accessTokenKey = null;
@@ -121,6 +124,7 @@
             this.accessTokenSecret = token.getSecret();
         }
     }
+*/    
 
     /**
      * Replies true if this holder contains an complete access token, consisting of an
@@ -143,6 +147,7 @@
     public void init(Preferences pref, CredentialsManager cm) throws IllegalArgumentException {
         CheckParameterUtil.ensureParameterNotNull(pref, "pref");
         CheckParameterUtil.ensureParameterNotNull(cm, "cm");
+/*
         OAuthToken token = null;
         try {
             token = cm.lookupOAuthAccessToken();
@@ -156,6 +161,7 @@
             accessTokenKey = token.getKey();
             accessTokenSecret = token.getSecret();
         }
+*/        
     }
 
     /**
@@ -171,6 +177,7 @@
         CheckParameterUtil.ensureParameterNotNull(preferences, "preferences");
         CheckParameterUtil.ensureParameterNotNull(cm, "cm");
         preferences.put("oauth.access-token.save-to-preferences", saveToPreferences);
+/*
         try {
             if (!saveToPreferences) {
                 cm.storeOAuthAccessToken(null);
@@ -182,6 +189,7 @@
             System.err.println(tr("Warning: Failed to store OAuth Access Token to credentials manager"));
             System.err.println(tr("Current credential manager is of type ''{0}''", cm.getClass().getName()));
         }
+*/        
     }
 
     /**
diff -uNr josm-0-3376-original/src/org/openstreetmap/josm/gui/preferences/server/OAuthAuthenticationPreferencesPanel.java josm-0/src/org/openstreetmap/josm/gui/preferences/server/OAuthAuthenticationPreferencesPanel.java
--- josm-0-3376-original/src/org/openstreetmap/josm/gui/preferences/server/OAuthAuthenticationPreferencesPanel.java	2010-03-05 10:54:39.000000000 +0100
+++ josm-0/src/org/openstreetmap/josm/gui/preferences/server/OAuthAuthenticationPreferencesPanel.java	2010-07-21 23:00:18.487143494 +0200
@@ -25,13 +25,17 @@
 import javax.swing.JTextField;
 
 import org.openstreetmap.josm.Main;
+/*
 import org.openstreetmap.josm.data.oauth.OAuthParameters;
 import org.openstreetmap.josm.data.oauth.OAuthToken;
+*/
 import org.openstreetmap.josm.gui.JMultilineLabel;
 import org.openstreetmap.josm.gui.SideButton;
+/*
 import org.openstreetmap.josm.gui.oauth.AdvancedOAuthPropertiesPanel;
 import org.openstreetmap.josm.gui.oauth.OAuthAuthorizationWizard;
 import org.openstreetmap.josm.gui.oauth.TestAccessTokenTask;
+*/
 import org.openstreetmap.josm.io.auth.CredentialsManagerFactory;
 import org.openstreetmap.josm.tools.ImageProvider;
 
@@ -50,7 +54,7 @@
     private JPanel pnlAuthorisationMessage;
     private NotYetAuthorisedPanel pnlNotYetAuthorised;
     private AlreadyAuthorisedPanel pnlAlreadyAuthorised;
-    private AdvancedOAuthPropertiesPanel pnlAdvancedProperties;
+//    private AdvancedOAuthPropertiesPanel pnlAdvancedProperties;
     private String apiUrl;
     private JCheckBox cbShowAdvancedParameters;
     private JCheckBox cbSaveToPreferences;
@@ -73,7 +77,7 @@
         cbShowAdvancedParameters.addItemListener(
                 new ItemListener() {
                     public void itemStateChanged(ItemEvent evt) {
-                        pnlAdvancedProperties.setVisible(evt.getStateChange() == ItemEvent.SELECTED);
+//                        pnlAdvancedProperties.setVisible(evt.getStateChange() == ItemEvent.SELECTED);
                     }
                 }
         );
@@ -90,6 +94,7 @@
         gc.fill = GridBagConstraints.BOTH;
         gc.weightx = 1.0;
         gc.weighty = 1.0;
+/*
         pnl.add(pnlAdvancedProperties = new AdvancedOAuthPropertiesPanel(), gc);
         pnlAdvancedProperties.initFromPreferences(Main.pref);
         pnlAdvancedProperties.setBorder(
@@ -99,6 +104,7 @@
                 )
         );
         pnlAdvancedProperties.setVisible(false);
+*/        
         return pnl;
     }
 
@@ -129,14 +135,15 @@
 
     protected void refreshView() {
         pnlAuthorisationMessage.removeAll();
-        if (OAuthAccessTokenHolder.getInstance().containsAccessToken()) {
+/*        if (OAuthAccessTokenHolder.getInstance().containsAccessToken()) {
             pnlAuthorisationMessage.add(pnlAlreadyAuthorised, BorderLayout.CENTER);
             pnlAlreadyAuthorised.refreshView();
             pnlAlreadyAuthorised.revalidate();
         } else {
+*/        
             pnlAuthorisationMessage.add(pnlNotYetAuthorised, BorderLayout.CENTER);
             pnlNotYetAuthorised.revalidate();
-        }
+//        }
         repaint();
     }
 
@@ -163,9 +170,11 @@
      * Saves the current values to preferences
      */
     public void saveToPreferences() {
+/*
         OAuthAccessTokenHolder.getInstance().setSaveToPreferences(cbSaveToPreferences.isSelected());
         OAuthAccessTokenHolder.getInstance().save(Main.pref, CredentialsManagerFactory.getCredentialManager());
         pnlAdvancedProperties.getAdvancedParameters().saveToPreferences(Main.pref);
+*/
     }
 
     /**
@@ -256,7 +265,7 @@
             gc.gridwidth = 2;
             gc.weightx = 1.0;
             add(cbSaveToPreferences = new JCheckBox(tr("Save to preferences")), gc);
-            cbSaveToPreferences.setSelected(OAuthAccessTokenHolder.getInstance().isSaveToPreferences());
+//            cbSaveToPreferences.setSelected(OAuthAccessTokenHolder.getInstance().isSaveToPreferences());
 
             // -- action buttons
             JPanel btns = new JPanel(new FlowLayout(FlowLayout.LEFT));
@@ -285,11 +294,12 @@
         }
 
         public void refreshView() {
-            String v = OAuthAccessTokenHolder.getInstance().getAccessTokenKey();
+/*            String v = OAuthAccessTokenHolder.getInstance().getAccessTokenKey();
             tfAccessTokenKey.setText(v == null? "" : v);
             v = OAuthAccessTokenHolder.getInstance().getAccessTokenSecret();
             tfAccessTokenSecret.setText(v == null? "" : v);
             cbSaveToPreferences.setSelected(OAuthAccessTokenHolder.getInstance().isSaveToPreferences());
+*/            
         }
 
         public AlreadyAuthorisedPanel() {
@@ -309,7 +319,7 @@
 
         }
         public void actionPerformed(ActionEvent arg0) {
-            OAuthAuthorizationWizard wizard = new OAuthAuthorizationWizard(
+/*            OAuthAuthorizationWizard wizard = new OAuthAuthorizationWizard(
                     OAuthAuthenticationPreferencesPanel.this,
                     apiUrl
             );
@@ -320,7 +330,8 @@
             holder.setSaveToPreferences(wizard.isSaveAccessTokenToPreferences());
             pnlAdvancedProperties.setAdvancedParameters(wizard.getOAuthParameters());
             refreshView();
-        }
+*/             
+        }       
     }
 
     /**
@@ -334,6 +345,7 @@
 
         }
         public void actionPerformed(ActionEvent arg0) {
+/*
             OAuthAuthorizationWizard wizard = new OAuthAuthorizationWizard(
                     OAuthAuthenticationPreferencesPanel.this,
                     apiUrl
@@ -345,6 +357,7 @@
             holder.setSaveToPreferences(wizard.isSaveAccessTokenToPreferences());
             pnlAdvancedProperties.setAdvancedParameters(wizard.getOAuthParameters());
             refreshView();
+*/            
         }
     }
 
@@ -360,6 +373,7 @@
         }
 
         public void actionPerformed(ActionEvent evt) {
+/*
             OAuthToken token = OAuthAccessTokenHolder.getInstance().getAccessToken();
             OAuthParameters parameters = OAuthParameters.createFromPreferences(Main.pref);
             TestAccessTokenTask task = new TestAccessTokenTask(
@@ -369,6 +383,7 @@
                     token
             );
             Main.worker.submit(task);
+*/            
         }
     }
 
diff -uNr josm-0-3376-original/src/org/openstreetmap/josm/io/auth/CredentialsManager.java josm-0/src/org/openstreetmap/josm/io/auth/CredentialsManager.java
--- josm-0-3376-original/src/org/openstreetmap/josm/io/auth/CredentialsManager.java	2010-03-05 10:54:39.000000000 +0100
+++ josm-0/src/org/openstreetmap/josm/io/auth/CredentialsManager.java	2010-07-21 23:00:18.487143494 +0200
@@ -4,7 +4,7 @@
 import java.net.PasswordAuthentication;
 import java.net.Authenticator.RequestorType;
 
-import org.openstreetmap.josm.data.oauth.OAuthToken;
+//import org.openstreetmap.josm.data.oauth.OAuthToken;
 
 /**
  * A CredentialManager manages two credentials:
@@ -57,7 +57,7 @@
      * @return the current OAuth Access Token to access the OSM server.
      * @throws CredentialsManagerException thrown if something goes wrong
      */
-    public OAuthToken lookupOAuthAccessToken() throws CredentialsManagerException;
+//    public OAuthToken lookupOAuthAccessToken() throws CredentialsManagerException;
 
     /**
      * Stores the OAuth Access Token <code>accessToken</code>.
@@ -65,5 +65,5 @@
      * @param accessToken the access Token. null, to remove the Access Token.
      * @throws CredentialsManagerException thrown if something goes wrong
      */
-    public void storeOAuthAccessToken(OAuthToken accessToken) throws CredentialsManagerException;
+//    public void storeOAuthAccessToken(OAuthToken accessToken) throws CredentialsManagerException;
 }
diff -uNr josm-0-3376-original/src/org/openstreetmap/josm/io/auth/JosmPreferencesCredentialManager.java josm-0/src/org/openstreetmap/josm/io/auth/JosmPreferencesCredentialManager.java
--- josm-0-3376-original/src/org/openstreetmap/josm/io/auth/JosmPreferencesCredentialManager.java	2010-06-26 21:09:24.000000000 +0200
+++ josm-0/src/org/openstreetmap/josm/io/auth/JosmPreferencesCredentialManager.java	2010-07-21 23:00:18.488143351 +0200
@@ -7,7 +7,7 @@
 import java.util.Map;
 
 import org.openstreetmap.josm.Main;
-import org.openstreetmap.josm.data.oauth.OAuthToken;
+//import org.openstreetmap.josm.data.oauth.OAuthToken;
 import org.openstreetmap.josm.gui.io.CredentialDialog;
 import org.openstreetmap.josm.gui.preferences.server.ProxyPreferencesPanel;
 
@@ -141,6 +141,7 @@
      * @return the current OAuth Access Token to access the OSM server.
      * @throws CredentialsManagerException thrown if something goes wrong
      */
+/*
     public OAuthToken lookupOAuthAccessToken() throws CredentialsManagerException {
         String accessTokenKey = Main.pref.get("oauth.access-token.key", null);
         String accessTokenSecret = Main.pref.get("oauth.access-token.secret", null);
@@ -148,14 +149,14 @@
             return null;
         return new OAuthToken(accessTokenKey, accessTokenSecret);
     }
-
+*/
     /**
      * Stores the OAuth Access Token <code>accessToken</code>.
      *
      * @param accessToken the access Token. null, to remove the Access Token.
      * @throws CredentialsManagerException thrown if something goes wrong
      */
-    public void storeOAuthAccessToken(OAuthToken accessToken) throws CredentialsManagerException {
+/*    public void storeOAuthAccessToken(OAuthToken accessToken) throws CredentialsManagerException {
         if (accessToken == null) {
             Main.pref.put("oauth.access-token.key", null);
             Main.pref.put("oauth.access-token.secret", null);
@@ -164,4 +165,5 @@
             Main.pref.put("oauth.access-token.secret", accessToken.getSecret());
         }
     }
+*/    
 }
diff -uNr josm-0-3376-original/src/org/openstreetmap/josm/io/OsmConnection.java josm-0/src/org/openstreetmap/josm/io/OsmConnection.java
--- josm-0-3376-original/src/org/openstreetmap/josm/io/OsmConnection.java	2010-06-26 21:09:24.000000000 +0200
+++ josm-0/src/org/openstreetmap/josm/io/OsmConnection.java	2010-07-21 23:00:18.488143351 +0200
@@ -12,12 +12,12 @@
 import java.nio.charset.CharsetEncoder;
 import java.util.logging.Logger;
 
-import oauth.signpost.OAuthConsumer;
-import oauth.signpost.exception.OAuthException;
+//import oauth.signpost.OAuthConsumer;
+//import oauth.signpost.exception.OAuthException;
 
 import org.openstreetmap.josm.Main;
-import org.openstreetmap.josm.data.oauth.OAuthParameters;
-import org.openstreetmap.josm.gui.preferences.server.OAuthAccessTokenHolder;
+//import org.openstreetmap.josm.data.oauth.OAuthParameters;
+//import org.openstreetmap.josm.gui.preferences.server.OAuthAccessTokenHolder;
 import org.openstreetmap.josm.io.auth.CredentialsManagerException;
 import org.openstreetmap.josm.io.auth.CredentialsManagerFactory;
 import org.openstreetmap.josm.io.auth.CredentialsManagerResponse;
@@ -35,7 +35,7 @@
 
     protected boolean cancel = false;
     protected HttpURLConnection activeConnection;
-    protected OAuthParameters oauthParameters;
+//    protected OAuthParameters oauthParameters;
 
     /**
      * Initialize the http defaults and the authenticator.
@@ -111,6 +111,7 @@
      * @throws OsmTransferException thrown if there is currently no OAuth Access Token configured
      * @throws OsmTransferException thrown if signing fails
      */
+/*
     protected void addOAuthAuthorizationHeader(HttpURLConnection connection) throws OsmTransferException {
         if (oauthParameters == null) {
             oauthParameters = OAuthParameters.createFromPreferences(Main.pref);
@@ -126,13 +127,16 @@
             throw new OsmTransferException(tr("Failed to sign a HTTP connection with an OAuth Authentication header"), e);
         }
     }
+*/    
 
     protected void addAuth(HttpURLConnection connection) throws OsmTransferException {
         String authMethod = Main.pref.get("osm-server.auth-method", "basic");
         if (authMethod.equals("basic")) {
             addBasicAuthorizationHeader(connection);
+/*
         } else if (authMethod.equals("oauth")) {
             addOAuthAuthorizationHeader(connection);
+*/
         } else {
             String msg = tr("Warning: unexpected value for preference ''{0}''. Got ''{1}''.", "osm-server.auth-method", authMethod);
             System.err.println(msg);
diff -uNr josm-0-3376-original/src/org/openstreetmap/josm/tools/ExceptionUtil.java josm-0/src/org/openstreetmap/josm/tools/ExceptionUtil.java
--- josm-0-3376-original/src/org/openstreetmap/josm/tools/ExceptionUtil.java	2010-05-15 21:57:19.000000000 +0200
+++ josm-0/src/org/openstreetmap/josm/tools/ExceptionUtil.java	2010-07-21 23:00:18.489143871 +0200
@@ -18,10 +18,10 @@
 import java.util.regex.Pattern;
 
 import org.openstreetmap.josm.Main;
-import org.openstreetmap.josm.gui.preferences.server.OAuthAccessTokenHolder;
+//import org.openstreetmap.josm.gui.preferences.server.OAuthAccessTokenHolder;
 import org.openstreetmap.josm.io.ChangesetClosedException;
 import org.openstreetmap.josm.io.IllegalDataException;
-import org.openstreetmap.josm.io.MissingOAuthAccessTokenException;
+//import org.openstreetmap.josm.io.MissingOAuthAccessTokenException;
 import org.openstreetmap.josm.io.OsmApi;
 import org.openstreetmap.josm.io.OsmApiException;
 import org.openstreetmap.josm.io.OsmApiInitializationException;
@@ -51,6 +51,7 @@
      *
      * @param e the exception
      */
+/*
     public static String explainMissingOAuthAccessTokenException(MissingOAuthAccessTokenException e) {
         e.printStackTrace();
         String msg = tr(
@@ -63,6 +64,7 @@
         );
         return msg;
     }
+*/
 
     /**
      * Explains a precondition exception when a child relation could not be deleted because
@@ -118,6 +120,7 @@
         );
     }
 
+/*
     public static String explainFailedOAuthAuthentication(OsmApiException e) {
         e.printStackTrace();
         return tr("<html>"
@@ -127,7 +130,9 @@
                 OAuthAccessTokenHolder.getInstance().getAccessTokenKey()
         );
     }
+*/    
 
+/*
     public static String explainFailedOAuthAuthorisation(OsmApiException e) {
         e.printStackTrace();
         return tr("<html>"
@@ -140,6 +145,7 @@
                 e.getAccessedUrl() == null ? tr("unknown") : e.getAccessedUrl()
         );
     }
+*/    
 
     /**
      * Explains an OSM API exception because of a client timeout (HTTP 408).