| 
									
										
										
										
											2022-12-24 05:47:50 +01:00
										 |  |  | <?php | 
					
						
							| 
									
										
										
										
											2023-01-15 15:47:25 +01:00
										 |  |  | 
 | 
					
						
							| 
									
										
										
										
											2023-07-15 16:02:42 +02:00
										 |  |  | /* | 
					
						
							|  |  |  |  * passport.php | 
					
						
							|  |  |  |  * Copyright (c) 2023 james@firefly-iii.org | 
					
						
							|  |  |  |  * | 
					
						
							|  |  |  |  * This file is part of Firefly III (https://github.com/firefly-iii). | 
					
						
							|  |  |  |  * | 
					
						
							|  |  |  |  * This program is free software: you can redistribute it and/or modify | 
					
						
							|  |  |  |  * it under the terms of the GNU Affero General Public License as | 
					
						
							|  |  |  |  * published by the Free Software Foundation, either version 3 of the | 
					
						
							|  |  |  |  * License, or (at your option) any later version. | 
					
						
							|  |  |  |  * | 
					
						
							|  |  |  |  * This program is distributed in the hope that it will be useful, | 
					
						
							|  |  |  |  * but WITHOUT ANY WARRANTY; without even the implied warranty of | 
					
						
							|  |  |  |  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the | 
					
						
							|  |  |  |  * GNU Affero General Public License for more details. | 
					
						
							|  |  |  |  * | 
					
						
							|  |  |  |  * You should have received a copy of the GNU Affero General Public License | 
					
						
							|  |  |  |  * along with this program.  If not, see <https://www.gnu.org/licenses/>. | 
					
						
							|  |  |  |  */ | 
					
						
							|  |  |  | 
 | 
					
						
							| 
									
										
										
										
											2022-12-24 05:52:34 +01:00
										 |  |  | declare(strict_types=1); | 
					
						
							| 
									
										
										
										
											2022-12-24 05:47:50 +01:00
										 |  |  | 
 | 
					
						
							|  |  |  | return [ | 
					
						
							|  |  |  |     /* | 
					
						
							|  |  |  |     |-------------------------------------------------------------------------- | 
					
						
							|  |  |  |     | Passport Guard | 
					
						
							|  |  |  |     |-------------------------------------------------------------------------- | 
					
						
							|  |  |  |     | | 
					
						
							|  |  |  |     | Here you may specify which authentication guard Passport will use when | 
					
						
							|  |  |  |     | authenticating users. This value should correspond with one of your | 
					
						
							|  |  |  |     | guards that is already present in your "auth" configuration file. | 
					
						
							|  |  |  |     | | 
					
						
							|  |  |  |     */ | 
					
						
							|  |  |  | 
 | 
					
						
							| 
									
										
										
										
											2024-01-01 14:45:51 +01:00
										 |  |  |     'guard'                  => envNonEmpty('AUTHENTICATION_GUARD', 'web'), | 
					
						
							| 
									
										
										
										
											2022-12-24 05:47:50 +01:00
										 |  |  | 
 | 
					
						
							|  |  |  |     /* | 
					
						
							|  |  |  |     |-------------------------------------------------------------------------- | 
					
						
							|  |  |  |     | Encryption Keys | 
					
						
							|  |  |  |     |-------------------------------------------------------------------------- | 
					
						
							|  |  |  |     | | 
					
						
							|  |  |  |     | Passport uses encryption keys while generating secure access tokens for | 
					
						
							|  |  |  |     | your application. By default, the keys are stored as local files but | 
					
						
							|  |  |  |     | can be set via environment variables when that is more convenient. | 
					
						
							|  |  |  |     | | 
					
						
							|  |  |  |     */ | 
					
						
							|  |  |  | 
 | 
					
						
							| 
									
										
										
										
											2024-01-01 14:45:51 +01:00
										 |  |  |     'private_key'            => env('PASSPORT_PRIVATE_KEY'), | 
					
						
							| 
									
										
										
										
											2022-12-24 05:47:50 +01:00
										 |  |  | 
 | 
					
						
							| 
									
										
										
										
											2024-01-01 14:45:51 +01:00
										 |  |  |     'public_key'             => env('PASSPORT_PUBLIC_KEY'), | 
					
						
							| 
									
										
										
										
											2022-12-24 05:47:50 +01:00
										 |  |  | 
 | 
					
						
							|  |  |  |     /* | 
					
						
							|  |  |  |     |-------------------------------------------------------------------------- | 
					
						
							|  |  |  |     | Client UUIDs | 
					
						
							|  |  |  |     |-------------------------------------------------------------------------- | 
					
						
							|  |  |  |     | | 
					
						
							|  |  |  |     | By default, Passport uses auto-incrementing primary keys when assigning | 
					
						
							|  |  |  |     | IDs to clients. However, if Passport is installed using the provided | 
					
						
							|  |  |  |     | --uuids switch, this will be set to "true" and UUIDs will be used. | 
					
						
							|  |  |  |     | | 
					
						
							|  |  |  |     */ | 
					
						
							|  |  |  | 
 | 
					
						
							| 
									
										
										
										
											2024-01-01 14:45:51 +01:00
										 |  |  |     'client_uuids'           => false, | 
					
						
							| 
									
										
										
										
											2022-12-24 05:47:50 +01:00
										 |  |  | 
 | 
					
						
							|  |  |  |     /* | 
					
						
							|  |  |  |     |-------------------------------------------------------------------------- | 
					
						
							|  |  |  |     | Personal Access Client | 
					
						
							|  |  |  |     |-------------------------------------------------------------------------- | 
					
						
							|  |  |  |     | | 
					
						
							|  |  |  |     | If you enable client hashing, you should set the personal access client | 
					
						
							|  |  |  |     | ID and unhashed secret within your environment file. The values will | 
					
						
							|  |  |  |     | get used while issuing fresh personal access tokens to your users. | 
					
						
							|  |  |  |     | | 
					
						
							|  |  |  |     */ | 
					
						
							|  |  |  | 
 | 
					
						
							|  |  |  |     'personal_access_client' => [ | 
					
						
							|  |  |  |         'id'     => env('PASSPORT_PERSONAL_ACCESS_CLIENT_ID'), | 
					
						
							|  |  |  |         'secret' => env('PASSPORT_PERSONAL_ACCESS_CLIENT_SECRET'), | 
					
						
							|  |  |  |     ], | 
					
						
							|  |  |  | ]; |