Package org.tmatesoft.svn.core.auth

Examples of org.tmatesoft.svn.core.auth.ISVNAuthenticationProvider


      }
      stored = getStoredServerCertificate(myRealm);
      if (data.equals(stored)) {
        return;
      }
      ISVNAuthenticationProvider authProvider = myAuthManager.getAuthenticationProvider();
      int failures = SVNSSLUtil.getServerCertificateFailures(certs[0], myURL.getHost());
      // compose bit mask.
      // 8 is default
      // check dates for 1 and 2
      // check host name for 4
      if (authProvider != null) {
        boolean store = myAuthManager.isAuthStorageEnabled();
        int result = authProvider.acceptServerAuthentication(myURL, myRealm, certs[0], store);
        if (result == ISVNAuthenticationProvider.ACCEPTED && store) {
          try {
            storeServerCertificate(myRealm, data, failures);
          } catch (SVNException e) {
            throw new SVNSSLUtil.CertificateNotTrustedException("svn: Server SSL ceritificate for '" + myRealm + "' cannot be saved");
View Full Code Here


      }
      stored = getStoredServerCertificate(myRealm);
      if (data.equals(stored)) {
        return;
      }
      ISVNAuthenticationProvider authProvider = myAuthManager.getAuthenticationProvider();
      int failures = SVNSSLUtil.getServerCertificateFailures(certs[0], myURL.getHost());
      // compose bit mask.
      // 8 is default
      // check dates for 1 and 2
      // check host name for 4
      if (authProvider != null) {
        boolean store = myAuthManager.isAuthStorageEnabled(myURL);
                boolean trustServer = checkServerTrustedByDefault(certs, algorithm);
                int result;
                if (trustServer) {
                    result = ISVNAuthenticationProvider.ACCEPTED;
                } else {
                    result = authProvider.acceptServerAuthentication(myURL, myRealm, certs[0], store);
                }
        if (result == ISVNAuthenticationProvider.ACCEPTED && store) {
          try {
            storeServerCertificate(myRealm, data, failures);
          } catch (SVNException e) {
View Full Code Here

                        }
                        stored = getStoredServerCertificate(myRealm);
                        if (data.equals(stored)) {
                            return;
                        }
                        ISVNAuthenticationProvider authProvider = myAuthManager.getAuthenticationProvider();
                        int failures = getServerCertificateFailures(certs[0]);
                        // compose bit mask.
                        // 8 is default
                        // check dates for 1 and 2
                        // check host name for 4
                        if (authProvider != null) {
                            boolean store = myAuthManager.isAuthStorageEnabled();
                            int result = authProvider.acceptServerAuthentication(myURL, myRealm, certs[0], store);
                            if (result == ISVNAuthenticationProvider.ACCEPTED && store) {
                                try {
                                    storeServerCertificate(myRealm, data, failures);
                                } catch (SVNException e) {
                                    CertificateException ce = new CertificateException("svn: Server SSL ceritificate for '" + myRealm + "' cannot be saved");
View Full Code Here

   */
  @Nonnull public List<String> getTags(@Nullable Job context) {
    List<String> dirs = new ArrayList<String>();

    try {
      ISVNAuthenticationProvider authProvider = CredentialsSVNAuthenticationProviderImpl.createAuthenticationProvider(
              context, getTagsDir(), getCredentialsId(), null
      );
      ISVNAuthenticationManager authManager = SubversionSCM.createSvnAuthenticationManager(authProvider);
      SVNURL repoURL = SVNURL.parseURIDecoded(getTagsDir());

View Full Code Here

                which will fail anyway. So our policy in the error handling in the polling
                is not to fire off builds. see HUDSON-6136.
             */
            revs.put(url, baseRev);
            try {
                ISVNAuthenticationProvider authProvider = authProviders.get(url);
                if (authProvider == null) {
                    authProvider = defaultAuthProvider;
                }
                final SVNURL svnurl = SVNURL.parseURIDecoded(url);
                long nowRev = new SvnInfo(SubversionSCM.parseSvnInfo(svnurl, authProvider)).revision;
View Full Code Here

        // work around for http://lib.svnkit.com/tracker/view.php?id=175
        th.setDocumentLocator(DUMMY_LOCATOR);
        logHandler.startDocument();

        for (ModuleLocation l : scm.getLocations(env, build)) {
            ISVNAuthenticationProvider authProvider =
                    CredentialsSVNAuthenticationProviderImpl
                            .createAuthenticationProvider(build.getParent(), scm, l);
            final SVNClientManager manager = SubversionSCM.createClientManager(authProvider).getCore();
            try {
                SVNLogClient svnlc = manager.getLogClient();
                PathContext context = getUrlForPath(workspace.child(l.getLocalDir()), authProvider);
                context.moduleWorkspacePath = l.getLocalDir();
                changelogFileCreated |= buildModule(context, svnlc, logHandler);
            } finally {
                manager.dispose();
            }
        }
        ISVNAuthenticationProvider authProvider =
                CredentialsSVNAuthenticationProviderImpl
                        .createAuthenticationProvider(build.getParent(), scm, null);
        final SVNClientManager manager = SubversionSCM.createClientManager(authProvider).getCore();
        try {
            SVNLogClient svnlc = manager.getLogClient();
View Full Code Here

      }
      stored = getStoredServerCertificate(myRealm);
      if (data.equals(stored)) {
        return;
      }
      ISVNAuthenticationProvider authProvider = myAuthManager.getAuthenticationProvider();
      int failures = SVNSSLUtil.getServerCertificateFailures(certs[0], myURL.getHost());
      // compose bit mask.
      // 8 is default
      // check dates for 1 and 2
      // check host name for 4
      if (authProvider != null) {
        boolean store = myAuthManager.isAuthStorageEnabled();
        int result = authProvider.acceptServerAuthentication(myURL, myRealm, certs[0], store);
        if (result == ISVNAuthenticationProvider.ACCEPTED && store) {
          try {
            storeServerCertificate(myRealm, data, failures);
          } catch (SVNException e) {
            throw new SVNSSLUtil.CertificateNotTrustedException("svn: Server SSL ceritificate for '" + myRealm + "' cannot be saved");
View Full Code Here

      }
      stored = getStoredServerCertificate(myRealm);
      if (data.equals(stored)) {
        return;
      }
      ISVNAuthenticationProvider authProvider = myAuthManager.getAuthenticationProvider();
      int failures = SVNSSLUtil.getServerCertificateFailures(certs[0], myURL.getHost());
      // compose bit mask.
      // 8 is default
      // check dates for 1 and 2
      // check host name for 4
      if (authProvider != null) {
        boolean store = myAuthManager.isAuthStorageEnabled();
        int result = authProvider.acceptServerAuthentication(myURL, myRealm, certs[0], store);
        if (result == ISVNAuthenticationProvider.ACCEPTED && store) {
          try {
            storeServerCertificate(myRealm, data, failures);
          } catch (SVNException e) {
            throw new SVNSSLUtil.CertificateNotTrustedException("svn: Server SSL ceritificate for '" + myRealm + "' cannot be saved");
View Full Code Here

TOP

Related Classes of org.tmatesoft.svn.core.auth.ISVNAuthenticationProvider

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.