Skip to content

Commit

Permalink
Merge pull request #620 from AzureAD/release/0.5.0
Browse files Browse the repository at this point in the history
Merge 0.5.0 release to master
  • Loading branch information
oldalton authored Aug 1, 2019
2 parents bc06096 + f5a8b10 commit 2b7c503
Show file tree
Hide file tree
Showing 178 changed files with 14,575 additions and 3,148 deletions.
3 changes: 3 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -2,3 +2,6 @@ xcuserdata
MSAL.xcscmblueprint
.DS_Store
*.pyc
## Build generated
build/
DerivedData/
2 changes: 1 addition & 1 deletion .travis.yml
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
language: objective-c
osx_image: xcode10
osx_image: xcode10.2

# Set up our rubygems (slather and xcpretty, namely)
install:
Expand Down
17 changes: 17 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,3 +1,10 @@
## [0.5.0] - 2019-07-30
### Updated
- Added initial macOS support
- Better resolution of authorities for silent token acquisition
- Added backward compatibility for legacy account storages
- Added backward compatibility for ADAL macOS cache

## [0.4.3] - 2019-05-24
### Updated
- Updated to newer v2 broker protocol version
Expand All @@ -16,6 +23,16 @@
- Added support for custom B2C domains
- Improved MSAL error handling

## [0.3.4] - 2019-03-07
### Fixed
- Improve logging for token removal scenarios
- Use ASCII for PKCE code challenge
- Don't return Access token if ID token/Account are missing

## [0.3.3] - 2019-05-29
### Updated
- Ignore cached fields in JSON if they contains "null"

## [0.3.2] - 2019-05-24
### Updated
- Updated to newer v2 broker protocol version
Expand Down
8 changes: 4 additions & 4 deletions MSAL.podspec
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
Pod::Spec.new do |s|
s.name = "MSAL"
s.version = "0.4.3"
s.version = "0.5.0"
s.summary = "Microsoft Authentication Library (MSAL) Preview for iOS"

s.description = <<-DESC
Expand Down Expand Up @@ -30,7 +30,7 @@ Pod::Spec.new do |s|

s.subspec 'app-lib' do |app|
app.source_files = "MSAL/src/**/*.{h,m}", "MSAL/IdentityCore/IdentityCore/src/**/*.{h,m}"
app.ios.public_header_files = "MSAL/src/public/*.h","MSAL/src/public/ios/*.h", "MSAL/src/public/configuration/**/*.h"
app.ios.public_header_files = "MSAL/src/public/*.h","MSAL/src/public/ios/**/*.h", "MSAL/src/public/configuration/**/*.h"
app.osx.public_header_files = "MSAL/src/public/mac/*.h","MSAL/src/public/*.h", "MSAL/src/public/configuration/**/*.h"

app.ios.exclude_files = "MSAL/src/**/mac/*", "MSAL/IdentityCore/IdentityCore/src/**/mac/*"
Expand All @@ -43,14 +43,14 @@ Pod::Spec.new do |s|
s.subspec 'extension' do |ext|
ext.compiler_flags = '-DADAL_EXTENSION_SAFE=1'
ext.source_files = "MSAL/src/**/*.{h,m}", "MSAL/IdentityCore/IdentityCore/src/**/*.{h,m}"
ext.ios.public_header_files = "MSAL/src/public/*.h","MSAL/src/public/ios/*.h", "MSAL/src/public/configuration/**/*.h"
ext.ios.public_header_files = "MSAL/src/public/*.h","MSAL/src/public/ios/**/*.h", "MSAL/src/public/configuration/**/*.h"
ext.osx.public_header_files = "MSAL/src/public/mac/*.h","MSAL/src/public/*.h", "MSAL/src/public/configuration/**/*.h"

# There is currently a bug in CocoaPods where it doesn't combine the public headers
# for both the platform and overall.
ext.ios.exclude_files = "MSAL/src/**/mac/*", "MSAL/IdentityCore/IdentityCore/src/**/mac/*"
ext.osx.exclude_files = "MSAL/src/**/ios/*", "MSAL/IdentityCore/IdentityCore/src/**/ios/*"

ext.requires_arc = true
end

end
2 changes: 1 addition & 1 deletion MSAL/IdentityCore
Submodule IdentityCore updated 323 files
1,157 changes: 908 additions & 249 deletions MSAL/MSAL.xcodeproj/project.pbxproj

Large diffs are not rendered by default.

Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
<plist version="1.0">
<dict>
<key>IDEDidComputeMac32BitWarning</key>
<true/>
</dict>
</plist>
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@
<BuildableReference
BuildableIdentifier = "primary"
BlueprintIdentifier = "04A6B59B2269286F0035C7C2"
BuildableName = "libMSAL.a"
BuildableName = "libMSAL (macOS Static Library).a"
BlueprintName = "MSAL (Mac Static Library)"
ReferencedContainer = "container:MSAL.xcodeproj">
</BuildableReference>
Expand Down Expand Up @@ -46,7 +46,7 @@
<BuildableReference
BuildableIdentifier = "primary"
BlueprintIdentifier = "04A6B59B2269286F0035C7C2"
BuildableName = "libMSAL.a"
BuildableName = "libMSAL (macOS Static Library).a"
BlueprintName = "MSAL (Mac Static Library)"
ReferencedContainer = "container:MSAL.xcodeproj">
</BuildableReference>
Expand All @@ -64,7 +64,7 @@
<BuildableReference
BuildableIdentifier = "primary"
BlueprintIdentifier = "04A6B59B2269286F0035C7C2"
BuildableName = "libMSAL.a"
BuildableName = "libMSAL (macOS Static Library).a"
BlueprintName = "MSAL (Mac Static Library)"
ReferencedContainer = "container:MSAL.xcodeproj">
</BuildableReference>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@
<BuildableReference
BuildableIdentifier = "primary"
BlueprintIdentifier = "04A6B57A226921890035C7C2"
BuildableName = "libMSAL.a"
BuildableName = "libMSAL (iOS Static Library).a"
BlueprintName = "MSAL (iOS Static Library)"
ReferencedContainer = "container:MSAL.xcodeproj">
</BuildableReference>
Expand Down Expand Up @@ -46,7 +46,7 @@
<BuildableReference
BuildableIdentifier = "primary"
BlueprintIdentifier = "04A6B57A226921890035C7C2"
BuildableName = "libMSAL.a"
BuildableName = "libMSAL (iOS Static Library).a"
BlueprintName = "MSAL (iOS Static Library)"
ReferencedContainer = "container:MSAL.xcodeproj">
</BuildableReference>
Expand All @@ -64,7 +64,7 @@
<BuildableReference
BuildableIdentifier = "primary"
BlueprintIdentifier = "04A6B57A226921890035C7C2"
BuildableName = "libMSAL.a"
BuildableName = "libMSAL (iOS Static Library).a"
BlueprintName = "MSAL (iOS Static Library)"
ReferencedContainer = "container:MSAL.xcodeproj">
</BuildableReference>
Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
<?xml version="1.0" encoding="UTF-8"?>
<Scheme
LastUpgradeVersion = "0820"
LastUpgradeVersion = "1010"
version = "1.3">
<BuildAction
parallelizeBuildables = "YES"
Expand All @@ -14,8 +14,8 @@
buildForAnalyzing = "YES">
<BuildableReference
BuildableIdentifier = "primary"
BlueprintIdentifier = "D61A646B1E5AA7120086D120"
BuildableName = "MSAL Test App.app"
BlueprintIdentifier = "1E614BD922558D8300EBF62F"
BuildableName = "MSAL Test App (Mac).app"
BlueprintName = "MSAL Test App (Mac)"
ReferencedContainer = "container:MSAL.xcodeproj">
</BuildableReference>
Expand All @@ -32,8 +32,8 @@
<MacroExpansion>
<BuildableReference
BuildableIdentifier = "primary"
BlueprintIdentifier = "D61A646B1E5AA7120086D120"
BuildableName = "MSAL Test App.app"
BlueprintIdentifier = "1E614BD922558D8300EBF62F"
BuildableName = "MSAL Test App (Mac).app"
BlueprintName = "MSAL Test App (Mac)"
ReferencedContainer = "container:MSAL.xcodeproj">
</BuildableReference>
Expand All @@ -55,8 +55,8 @@
runnableDebuggingMode = "0">
<BuildableReference
BuildableIdentifier = "primary"
BlueprintIdentifier = "D61A646B1E5AA7120086D120"
BuildableName = "MSAL Test App.app"
BlueprintIdentifier = "1E614BD922558D8300EBF62F"
BuildableName = "MSAL Test App (Mac).app"
BlueprintName = "MSAL Test App (Mac)"
ReferencedContainer = "container:MSAL.xcodeproj">
</BuildableReference>
Expand All @@ -74,8 +74,8 @@
runnableDebuggingMode = "0">
<BuildableReference
BuildableIdentifier = "primary"
BlueprintIdentifier = "D61A646B1E5AA7120086D120"
BuildableName = "MSAL Test App.app"
BlueprintIdentifier = "1E614BD922558D8300EBF62F"
BuildableName = "MSAL Test App (Mac).app"
BlueprintName = "MSAL Test App (Mac)"
ReferencedContainer = "container:MSAL.xcodeproj">
</BuildableReference>
Expand Down
2 changes: 1 addition & 1 deletion MSAL/resources/ios/Info.plist
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@
<key>CFBundlePackageType</key>
<string>FMWK</string>
<key>CFBundleShortVersionString</key>
<string>0.4.3</string>
<string>0.5.0</string>
<key>CFBundleVersion</key>
<string>$(CURRENT_PROJECT_VERSION)</string>
<key>NSPrincipalClass</key>
Expand Down
2 changes: 1 addition & 1 deletion MSAL/resources/mac/Info.plist
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@
<key>CFBundlePackageType</key>
<string>FMWK</string>
<key>CFBundleShortVersionString</key>
<string>0.4.3</string>
<string>0.5.0</string>
<key>CFBundleVersion</key>
<string>$(CURRENT_PROJECT_VERSION)</string>
<key>NSHumanReadableCopyright</key>
Expand Down
52 changes: 20 additions & 32 deletions MSAL/src/MSALAccount+Internal.h
Original file line number Diff line number Diff line change
Expand Up @@ -26,53 +26,41 @@
//------------------------------------------------------------------------------

#import "MSALAccount.h"
#import "MSALTenantProfile+Internal.h"

@class MSIDAccountIdentifier;
@class MSIDAADV2IdTokenClaims;
@class MSIDClientInfo;
@class MSIDAccount;
@class MSALAccountId;
@class MSIDIdTokenClaims;
@protocol MSALAccount;
@class MSALOauth2Provider;

@interface MSALAccount ()

@property (nonatomic) MSALAccountId *homeAccountId;
@property (nonatomic) NSString *username;
@property (nonatomic) NSString *environment;
@property (nonatomic) NSMutableArray<MSALTenantProfile *> *mTenantProfiles;
@property (nonatomic) NSDictionary<NSString *, NSString *> *accountClaims;
@property (nonatomic) NSString *identifier;
@property (nonatomic) MSIDAccountIdentifier *lookupAccountIdentifier;

/* TODO: These properties will be public once we agree on having an account per tenant.
For now, will keep them here.
*/

/*!
Account identifier for the target tenant
*/
@property (nonatomic) MSALAccountId *localAccountId;

/*!
The displayable name of the account. Can be nil if not returned by the service.
*/
@property (nonatomic) NSString *name;


/*!
Initialize an MSALAccount with given information
@param username The username value in UserPrincipleName(UPN) format
@param name The given name of the user
@param homeAccountId Unique identifier of the account in the home directory
@param localAccountId Unique identifier of the account in the signed in directory.
@param environment Host part of the authority string
@param tenantId An identifier for the tenant that the account was acquired from
*/
- (id)initWithUsername:(NSString *)username
name:(NSString *)name
homeAccountId:(NSString *)homeAccountId
localAccountId:(NSString *)localAccountId
environment:(NSString *)environment
tenantId:(NSString *)tenantId;
- (instancetype)initWithUsername:(NSString *)username
homeAccountId:(MSALAccountId *)homeAccountId
environment:(NSString *)environment
tenantProfiles:(NSArray<MSALTenantProfile *> *)tenantProfiles;

/*!
Initialize an MSALAccount with MSIDAccount
@param account MSID account
@param createTenantProfile Whether to create tenant profile based on the info of MSID account
*/
- (id)initWithMSIDAccount:(MSIDAccount *)account;
- (instancetype)initWithMSIDAccount:(MSIDAccount *)account createTenantProfile:(BOOL)createTenantProfile;
- (instancetype)initWithMSALExternalAccount:(id<MSALAccount>)externalAccount
oauth2Provider:(MSALOauth2Provider *)oauthProvider;

- (void)addTenantProfiles:(NSArray<MSALTenantProfile *> *)tenantProfiles;

@end
Loading

0 comments on commit 2b7c503

Please sign in to comment.