Skip to content

Commit c49aca0

Browse files
committed
chore: update docs for new auth
1 parent f09d2fa commit c49aca0

File tree

1 file changed

+64
-0
lines changed

1 file changed

+64
-0
lines changed

docs/authentication.md

+64
Original file line numberDiff line numberDiff line change
@@ -190,6 +190,70 @@ capabilities: {
190190

191191
<!-- tabs:end -->
192192

193+
### SAP BTP with Client Certificate Authentication
194+
195+
?> only available in `wdi5` >= 2
196+
197+
This authentication method will authenticate you with the certificate you get from [SAP Passport](https://support.sap.com/en/my-support/single-sign-on-passports.html).
198+
This way avoids the need to use the login process of the application you are testing.
199+
It is recommended to put the passphrase in an environment variable.
200+
For pipelines, you can create the PFX file from the base64 encoded secret and put the passphrase in an environment variable.
201+
See the [GitHub Actions workflow](https://github.com/ui5-community/wdi5/blob/main/.github/workflows/wdi5-tests_auth.yml#L76) as an example on how to use this authentication method in a pipeline.
202+
203+
<!-- tabs:start -->
204+
205+
#### **single browser**
206+
207+
```js
208+
baseUrl: "https://your-deployed-ui5-on-btp.app",
209+
capabilities: {
210+
// browserName: "..."
211+
"wdi5:authentication": {
212+
provider: "Certificate",
213+
certificateOrigin: "https://accounts.sap.com", // this should always be accounts.sap.com
214+
certificateUrl: "https://emea.cockpit.btp.cloud.sap/cockpit#/", // this is opened in the browser for authentication, if not specified the configured `baseUrl` is used
215+
certificatePfxPath: "./sap.pfx",
216+
certificatePfxPassword: process.env.SAPPFX_PASSPHRASE
217+
}
218+
}
219+
```
220+
221+
#### **multiremote**
222+
223+
```js
224+
baseUrl: "https://your-deployed-ui5-on-btp.app",
225+
capabilities: {
226+
// "one" is the literal reference to a browser instance
227+
one: {
228+
capabilities: {
229+
// browserName: "..."
230+
"wdi5:authentication": {
231+
provider: "Certificate",
232+
certificateOrigin: "https://accounts.sap.com", // this should always be accounts.sap.com
233+
certificateUrl: "https://emea.cockpit.btp.cloud.sap/cockpit#/", // this is opened in the browser for authentication, if not specified the configured `baseUrl` is used
234+
certificatePfxPath: "./sap.pfx",
235+
certificatePfxPassword: process.env.SAPPFX_PASSPHRASE
236+
}
237+
}
238+
},
239+
// "two" is the literal reference to a browser instance
240+
two: {
241+
capabilities: {
242+
// browserName: "..."
243+
"wdi5:authentication": {
244+
provider: "Certificate",
245+
certificateOrigin: "https://accounts.sap.com", // this should always be accounts.sap.com
246+
certificateUrl: "https://emea.cockpit.btp.cloud.sap/cockpit#/", // this is opened in the browser for authentication, if not specified the configured `baseUrl` is used
247+
certificatePfxPath: "./sap.pfx",
248+
certificatePfxPassword: process.env.SAPPFX_PASSPHRASE
249+
}
250+
}
251+
}
252+
}
253+
```
254+
255+
<!-- tabs:end -->
256+
193257
### Office 365
194258

195259
<!-- tabs:start -->

0 commit comments

Comments
 (0)