Skip to content

Commit

Permalink
Merge pull request #21 from nevissecurity/feature/introduce-dokka-api…
Browse files Browse the repository at this point in the history
…-doc-generator

Introduce Dokka API doc generator
  • Loading branch information
tamas-toth authored Aug 6, 2024
2 parents f5ccc4f + fbd9686 commit 3cce294
Show file tree
Hide file tree
Showing 160 changed files with 1,674 additions and 669 deletions.
13 changes: 12 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -220,6 +220,17 @@ The example application wraps the SDK calls in the use-case implementations in t

As an example check the [InBandAuthenticationUseCaseImpl](app/src/main/java/ch/nevis/exampleapp/coroutines/domain/usecase/InBandAuthenticationUseCaseImpl.kt) and the [AuthenticatorSelectorImpl](app/src/main/java/ch/nevis/exampleapp/coroutines/domain/interaction/AuthenticatorSelectorImpl.kt) classes.

### KDoc & Dokka

The source code is documented using [KDoc](https://kotlinlang.org/docs/kotlin-doc.html) syntax. [Dokka](https://kotlinlang.org/docs/dokka-introduction.html) is an API documentation engine for Kotlin.
Documentation can be generated by running:

```bash
./gradlew dokkaHtml dokkaHtmlMultiModule
```

The output can be found in the `build/dokka/htmlMultiModule` folder.

## Integration Notes

In this section you can find hints about how the Nevis Mobile Authentication SDK is integrated into the example app.
Expand Down Expand Up @@ -288,4 +299,4 @@ The following use cases are responsible for getting information with the help of
- The [GetAuthenticatorsUseCaseImpl](app/src/main/java/ch/nevis/exampleapp/coroutines/domain/usecase/GetAuthenticatorsUseCaseImpl.kt) class obtains the authenticator information.
- The [GetDeviceInformationUseCaseImpl](app/src/main/java/ch/nevis/exampleapp/coroutines/domain/usecase/GetDeviceInformationUseCaseImpl.kt) class obtains the device information.

© 2023 made with ❤ by Nevis
© 2024 made with ❤ by Nevis
217 changes: 217 additions & 0 deletions app/module.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,217 @@
# Module nevis-mobile-authentication-example-coroutines-app

## Description

The example app demonstrating how to use the Nevis Mobile Authentication SDK in an Android mobile application.
The Nevis Mobile Authentication SDK allows you to integrate passwordless authentication to your existing mobile app, backed by the FIDO UAF 1.1 Standard.

Some SDK features demonstrated in this example app are:

- Using the SDK with the Nevis Authentication Cloud
- Registering with QR code & app link URIs
- Simulating in-band authentication after registration
- Deregistering a registered account
- Changing the PIN of the PIN authenticator
- Changing the device information

Please note that the example app only demonstrates a subset of the available SDK features. The main purpose is to demonstrate how the SDK can be used, not to cover all supported scenarios.

# Package ch.nevis.exampleapp.coroutines.application

This package contains a sub-class of `Application` to enable Dagger Hilt capabilities and to initialize logging.

# Package ch.nevis.exampleapp.coroutines.common.configuration

This package contains the configuration possibilities of the Nevis Mobile Authentication SDK.

# Package ch.nevis.exampleapp.coroutines.common.error

This package contains the error handling related classes.

# Package ch.nevis.exampleapp.coroutines.common.settings

This package contains the application settings possibilities.

# Package ch.nevis.exampleapp.coroutines.dagger

This package contains the main Dagger Hilt configuration module.

# Package ch.nevis.exampleapp.coroutines.data.cache

This package contains caching related implementations.

# Package ch.nevis.exampleapp.coroutines.data.dataSource

This package contains data source implementations.

# Package ch.nevis.exampleapp.coroutines.data.dataSource

This package contains model definitions.

# Package ch.nevis.exampleapp.coroutines.data.repository

This package contains repository implementations.

# Package ch.nevis.exampleapp.coroutines.data.retrofit

This package contains the `Retrofit` networking framework integration.

# Package ch.nevis.exampleapp.coroutines.domain.client

This package contains the `MobileAuthenticationClient` provider.

# Package ch.nevis.exampleapp.coroutines.domain.interaction

This package contains the default implementation of interaction related interfaces from the Nevis Mobile Authentication SDK, like account and authenticator selection and user verification.

# Package ch.nevis.exampleapp.coroutines.domain.interaction.password

This package contains the default implementation of password interaction related interfaces from the Nevis Mobile Authentication SDK, like changing, enrolling and verifying the password.

# Package ch.nevis.exampleapp.coroutines.domain.interaction.pin

This package contains the default implementation of PIN interaction related interfaces from the Nevis Mobile Authentication SDK, like changing, enrolling and verifying the PIN.

# Package ch.nevis.exampleapp.coroutines.domain.log

This package contains logging related implementations.

# Package ch.nevis.exampleapp.coroutines.domain.model.error

This package contains error handling related model definitions.

# Package ch.nevis.exampleapp.coroutines.domain.model.operation

This package contains operation related model definitions.

# Package ch.nevis.exampleapp.coroutines.domain.model.response

This package contains operation related response model definitions.

# Package ch.nevis.exampleapp.coroutines.domain.model.sdk

This package contains Nevis Mobile Authentication SDK related model definitions.

# Package ch.nevis.exampleapp.coroutines.domain.model.state

This package contains operation related state definitions.

# Package ch.nevis.exampleapp.coroutines.domain.repository

This package contains repository definitions.

# Package ch.nevis.exampleapp.coroutines.domain.usecase

This package contains use case definitions and implementations.

# Package ch.nevis.exampleapp.coroutines.domain.util

This package contains Nevis Mobile Authentication SDK related extension definitions.

# Package ch.nevis.exampleapp.coroutines.domain.validation

This package contains validation related logic.

# Package ch.nevis.exampleapp.coroutines.timber

This package contains the `Timber` logging framework integration.

# Package ch.nevis.exampleapp.coroutines.ui.authCloudRegistration

This package contains the view and view model definitions for the Auth Cloud API Registration operation.

# Package ch.nevis.exampleapp.coroutines.ui.base

This package contains the base view and view model definitions.

# Package ch.nevis.exampleapp.coroutines.ui.changeDeviceInformation

This package contains the view and view model definitions for the Change Device Information operation.

# Package ch.nevis.exampleapp.coroutines.ui.credential

This package contains the view and view model definitions for credential related operations, like change, enroll or verify a PIN or password.

# Package ch.nevis.exampleapp.coroutines.ui.credential.model

This package contains the model definitions for credential related operations.

# Package ch.nevis.exampleapp.coroutines.ui.credential.parameter

This package contains the navigation parameter definitions for credential related operations.

# Package ch.nevis.exampleapp.coroutines.ui.error

This package contains the view definition for error handling.

# Package ch.nevis.exampleapp.coroutines.ui.error.parameter

This package contains the navigation parameter definitions for error handling.

# Package ch.nevis.exampleapp.coroutines.ui.home

This package contains the view and view model definitions for the Home feature.

# Package ch.nevis.exampleapp.coroutines.ui.legacyLogin

This package contains the view and view model definitions for In-Band Registration operation.

# Package ch.nevis.exampleapp.coroutines.ui.main

This package contains the main activity and view model definitions.

# Package ch.nevis.exampleapp.coroutines.ui.qrReader

This package contains the view and view model definitions for Qr Code reading.

# Package ch.nevis.exampleapp.coroutines.ui.result

This package contains the view definition for displaying operation result.

# Package ch.nevis.exampleapp.coroutines.ui.result.parameter

This package contains the navigation parameter definitions for displaying operation result.

# Package ch.nevis.exampleapp.coroutines.ui.selectAccount

This package contains the view and view model definitions for account selection.

# Package ch.nevis.exampleapp.coroutines.ui.selectAccount.parameter

This package contains the navigation parameter definitions for account selection.

# Package ch.nevis.exampleapp.coroutines.ui.selectAuthenticator

This package contains the view and view model definitions for authenticator selection.

# Package ch.nevis.exampleapp.coroutines.ui.selectAuthenticator.model

This package contains the model definitions for authenticator selection.

# Package ch.nevis.exampleapp.coroutines.ui.selectAuthenticator.parameter

This package contains the navigation parameter definitions for authenticator selection.

# Package ch.nevis.exampleapp.coroutines.ui.transactionConfirmation

This package contains the view and view model definitions for transaction confirmation.

# Package ch.nevis.exampleapp.coroutines.ui.transactionConfirmation.parameter

This package contains the navigation parameter definitions for transaction confirmation.

# Package ch.nevis.exampleapp.coroutines.ui.util

This package contains utility methods.

# Package ch.nevis.exampleapp.coroutines.ui.verifyUser

This package contains the view and view model definitions for user verification.

# Package ch.nevis.exampleapp.coroutines.ui.verifyUser.model

This package contains the model definitions for user verification.

# Package ch.nevis.exampleapp.coroutines.ui.verifyUser.parameter

This package contains the navigation parameter definitions for user verification.
Original file line number Diff line number Diff line change
Expand Up @@ -26,10 +26,11 @@ class ExampleApplication: Application() {
lateinit var sdkLogger: SdkLogger

//region Application
/** @suppress */
override fun onCreate() {
super.onCreate()

Timber.plant(ExampleAppTree(sdkLogger))
}
//endregion
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,9 @@ import timber.log.Timber

/**
* Implementation of [ErrorHandler] interface for cases the user cancels an operation.
*
* @constructor Creates a new instance.
* @param navController The navigation controller.
*/
class CancelErrorHandlerImpl(
private val navController: NavController
Expand Down Expand Up @@ -61,4 +64,4 @@ class CancelErrorHandlerImpl(
}
}
//endregion
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,10 @@ import timber.log.Timber

/**
* Default implementation of [ErrorHandler] interface.
*
* @constructor Creates a new instance.
* @param context An Android [Context] object for [String] resource resolving.
* @param navController The navigation controller.
*/
class DefaultErrorHandlerImpl(
private val context: Context,
Expand Down Expand Up @@ -66,4 +70,4 @@ class DefaultErrorHandlerImpl(
return throwable.message ?: throwable.stackTraceToString()
}
//endregion
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,8 @@ package ch.nevis.exampleapp.coroutines.common.error

/**
* Default implementation of [ErrorHandlerChain] interface.
*
* @constructor Creates a new instance.
*/
class ErrorHandlerChainImpl : ErrorHandlerChain {

Expand Down Expand Up @@ -37,4 +39,4 @@ class ErrorHandlerChainImpl : ErrorHandlerChain {
}
}
//endregion
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,10 @@ interface Settings {
* by requiring user authentication.
* However in some cases it may be acceptable for the sake of end-user convenience. Allowing Class 2
* sensors will enable for instance the use of face recognition in some Samsung devices.
*
* @see ch.nevis.mobile.sdk.api.operation.authcloudapi.AuthCloudApiRegistration
* @see ch.nevis.mobile.sdk.api.operation.outofband.OutOfBandRegistration
* @see ch.nevis.mobile.sdk.api.operation.Registration.allowClass2Sensors
*/
val allowClass2Sensors: Boolean
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,9 @@ import javax.inject.Inject

/**
* Default implementation of [Settings] interface.
*
* @constructor Creates a new instance.
* @param context The Android [Context].
*/
class SettingsImpl @Inject constructor(
@ApplicationContext
Expand Down
Loading

0 comments on commit 3cce294

Please sign in to comment.