Changeset 10746 in josm for trunk/src/oauth


Ignore:
Timestamp:
2016-08-06T16:52:01+02:00 (8 years ago)
Author:
Don-vip
Message:

see #11390, see #11924 - replace javax.xml.bind.DatatypeConverter (not visible by default in Java 9) by java.util.Base64 (new in Java 8)

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/oauth/signpost/signature/OAuthMessageSigner.java

    r8149 r10746  
    1717import java.io.IOException;
    1818import java.io.Serializable;
    19 import javax.xml.bind.DatatypeConverter;
     19import java.util.Base64;
    2020
    2121import oauth.signpost.exception.OAuthMessageSignerException;
     
    5454
    5555    protected byte[] decodeBase64(String s) {
    56         return DatatypeConverter.parseBase64Binary(s);
     56        return Base64.getDecoder().decode(s);
    5757    }
    5858
    5959    protected String base64Encode(byte[] b) {
    60         return DatatypeConverter.printBase64Binary(b);
     60        return Base64.getEncoder().encodeToString(b);
    6161    }
    6262
Note: See TracChangeset for help on using the changeset viewer.