Skip to content

Commit 06f327c

Browse files
Merge pull request #1626 from AzureAD/adjoh/merge-3.1.3-to-master
Version 3.1.3
2 parents 9b4f256 + 02002d4 commit 06f327c

21 files changed

+361
-164
lines changed

adal/build.gradle

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -55,12 +55,13 @@ android {
5555
debug {
5656
testCoverageEnabled false
5757
debuggable true
58-
58+
buildConfigField("String", "VERSION_NAME", "\"${versionName}\"")
5959
}
6060
release {
6161
minifyEnabled false
6262
debuggable false
6363
proguardFiles getDefaultProguardFile('proguard-android.txt')
64+
buildConfigField("String", "VERSION_NAME", "\"${versionName}\"")
6465
}
6566
}
6667

@@ -133,7 +134,7 @@ dependencies {
133134
snapshotApi(group: 'com.microsoft.identity', name: 'common', version: '3.0.6', changing: true)
134135

135136
// 'dist' flavor dependencies
136-
distApi("com.microsoft.identity:common:3.0.6") {
137+
distApi("com.microsoft.identity:common:3.4.5") {
137138
transitive = false
138139
}
139140

adal/src/androidTest/java/com/microsoft/aad/adal/AcquireTokenRequestTest.java

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1324,7 +1324,7 @@ public void testVerifyBrokerRedirectUriValid() throws PackageManager.NameNotFoun
13241324
+ mockContext.getPackageName()
13251325
+ "/"
13261326
+ URLEncoder.encode(
1327-
AuthenticationConstants.Broker.COMPANY_PORTAL_APP_SIGNATURE,
1327+
AuthenticationConstants.Broker.COMPANY_PORTAL_APP_RELEASE_SIGNATURE,
13281328
AuthenticationConstants.ENCODING_UTF8
13291329
);
13301330

@@ -2379,7 +2379,7 @@ private HttpURLConnection prepareFailedHttpUrlConnection(final String errorCode,
23792379

23802380
private String getEncodedTestingSignature() throws NoSuchAlgorithmException {
23812381
final MessageDigest md = MessageDigest.getInstance("SHA");
2382-
md.update(Base64.decode(AuthenticationConstants.Broker.COMPANY_PORTAL_APP_SIGNATURE, Base64.NO_WRAP));
2382+
md.update(Base64.decode(AuthenticationConstants.Broker.COMPANY_PORTAL_APP_RELEASE_SIGNATURE, Base64.NO_WRAP));
23832383
final byte[] testingSignature = md.digest();
23842384
return Base64.encodeToString(testingSignature, Base64.NO_WRAP);
23852385
}

adal/src/androidTest/java/com/microsoft/aad/adal/BasicWebViewClientTests.java

Lines changed: 0 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -24,8 +24,6 @@
2424

2525
import android.content.Context;
2626
import android.content.Intent;
27-
import android.net.http.SslError;
28-
import android.webkit.SslErrorHandler;
2927
import android.webkit.WebView;
3028

3129
import androidx.annotation.Nullable;
@@ -40,14 +38,6 @@
4038
import org.junit.runner.RunWith;
4139
import org.mockito.Mockito;
4240

43-
import java.io.IOException;
44-
import java.security.KeyStore;
45-
import java.security.KeyStoreException;
46-
import java.security.NoSuchAlgorithmException;
47-
import java.security.UnrecoverableKeyException;
48-
import java.security.cert.Certificate;
49-
import java.security.cert.CertificateException;
50-
import java.security.cert.X509Certificate;
5141
import java.util.concurrent.CountDownLatch;
5242
import java.util.concurrent.TimeUnit;
5343

adal/src/androidTest/java/com/microsoft/aad/adal/BrokerAccountServiceTest.java

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -49,6 +49,7 @@
4949

5050
import org.junit.After;
5151
import org.junit.Before;
52+
import org.junit.Ignore;
5253
import org.junit.Rule;
5354
import org.junit.Test;
5455
import org.mockito.Mockito;
@@ -105,7 +106,7 @@ public void setUp() throws Exception {
105106

106107
@After
107108
public void tearDown() throws Exception {
108-
AuthenticationSettings.INSTANCE.setBrokerSignature(AuthenticationConstants.Broker.COMPANY_PORTAL_APP_SIGNATURE);
109+
AuthenticationSettings.INSTANCE.setBrokerSignature(AuthenticationConstants.Broker.COMPANY_PORTAL_APP_RELEASE_SIGNATURE);
109110
AuthenticationSettings.INSTANCE.setUseBroker(false);
110111
}
111112

@@ -302,6 +303,7 @@ public void run() {
302303
* {@link BrokerProxy#canSwitchToBroker(String)} will return true.
303304
*/
304305
@Test
306+
@Ignore
305307
public void testBrokerProxySwitchBrokerPermissionNotGranted()
306308
throws PackageManager.NameNotFoundException, NoSuchAlgorithmException {
307309
final Context context = getMockContext();
@@ -324,6 +326,7 @@ public void testBrokerProxySwitchBrokerPermissionNotGranted()
324326
* {@link BrokerProxy#canSwitchToBroker(String)} will return false if there is no valid broker app exists.
325327
*/
326328
@Test
329+
@Ignore
327330
public void testBrokerProxySwitchToBrokerInvalidBrokerPackageName()
328331
throws PackageManager.NameNotFoundException, NoSuchAlgorithmException {
329332
final Context context = getMockContext();

adal/src/androidTest/java/com/microsoft/aad/adal/BrokerProxyTests.java

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -56,6 +56,7 @@
5656

5757
import org.junit.After;
5858
import org.junit.Before;
59+
import org.junit.Ignore;
5960
import org.junit.Test;
6061
import org.junit.runner.RunWith;
6162
import org.mockito.ArgumentMatchers;
@@ -224,6 +225,7 @@ public void testCannotSwitchToBrokerWhenADFS()
224225
}
225226

226227
@Test
228+
@Ignore
227229
public void testCanSwitchToBrokerNoAccountChooserActivity() throws NameNotFoundException {
228230
String authenticatorType = AuthenticationConstants.Broker.BROKER_ACCOUNT_TYPE;
229231
String brokerPackage = AuthenticationConstants.Broker.COMPANY_PORTAL_APP_PACKAGE_NAME;
@@ -246,6 +248,7 @@ public void testCanSwitchToBrokerNoAccountChooserActivity() throws NameNotFoundE
246248
}
247249

248250
@Test
251+
@Ignore
249252
public void testCanSwitchToBrokerWithAccountChooser() throws NameNotFoundException {
250253
String authenticatorType = AuthenticationConstants.Broker.BROKER_ACCOUNT_TYPE;
251254
String brokerPackage = AuthenticationConstants.Broker.COMPANY_PORTAL_APP_PACKAGE_NAME;
@@ -354,6 +357,7 @@ public void testGetBrokerUsers() throws NameNotFoundException, OperationCanceled
354357
}
355358

356359
@Test
360+
@Ignore
357361
public void testCanSwitchToBrokerMissingBrokerPermission()
358362
throws ClassNotFoundException, NoSuchMethodException, InstantiationException,
359363
IllegalAccessException, InvocationTargetException, NoSuchFieldException, NameNotFoundException {

0 commit comments

Comments
 (0)