1
0
Fork 0
mirror of synced 2024-06-28 19:20:25 +12:00

Merge pull request #63 from christyjacob4/master

Added Support for BitBucket OAuth
This commit is contained in:
Eldad A. Fux 2019-10-01 18:59:05 +03:00 committed by GitHub
commit 4c5e3947b0
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
17 changed files with 573 additions and 441 deletions

View file

@ -1,4 +1,4 @@
<?php
<?php
/**
* List Of World Currencies.

View file

@ -1,11 +1,11 @@
<?php
return [
'AF' => 'Àfrica',
'AN' => 'Antàrtica',
'AS' => 'Àsia',
'EU' => 'Europa',
'NA' => 'Amèrica del Nord',
'OC' => 'Oceania',
'SA' => 'Amèrica del Sud',
];
<?php
return [
'AF' => 'Àfrica',
'AN' => 'Antàrtica',
'AS' => 'Àsia',
'EU' => 'Europa',
'NA' => 'Amèrica del Nord',
'OC' => 'Oceania',
'SA' => 'Amèrica del Sud',
];

View file

@ -1,197 +1,197 @@
<?php
return [
'AF' => 'Afganistan',
'AO' => 'Angola',
'AL' => 'Albània',
'AD' => 'Andorra',
'AE' => 'Unió dels Emirats Àrabs Units',
'AR' => 'Argentina',
'AM' => 'Armènia',
'AG' => 'Antigua o Barbuda',
'AU' => 'Austràlia',
'AT' => 'Àustria',
'AZ' => 'Azerbaidjan',
'BI' => 'Burundi',
'BE' => 'Bèlgica',
'BJ' => 'Benín',
'BF' => 'Burkina Faso',
'BD' => 'Bangla Desh',
'BG' => 'Bulgaria',
'BH' => 'Bahrain',
'BS' => 'Bahamas',
'BA' => 'Bòsnia i Hercegovina',
'BY' => 'Bielorússia',
'BZ' => 'Belize',
'BO' => 'Bolívia',
'BR' => 'Brasil',
'BB' => 'Barbados',
'BN' => 'Brunei',
'BT' => 'Bhutan',
'BW' => 'Botswana',
'CF' => 'República Centreafricana',
'CA' => 'Canadà',
'CH' => 'Suïssa',
'CL' => 'Xile',
'CN' => 'Xina',
'CI' => 'Costa d\'Ivori',
'CM' => 'Camerun',
'CD' => 'República Democràtica del Congo',
'CG' => 'República del congo',
'CO' => 'Colòmbia',
'KM' => 'Comores',
'CV' => 'Cap Verd',
'CR' => 'Costa Rica',
'CU' => 'Cuba',
'CY' => 'Xipre',
'CZ' => 'Txèquia',
'DE' => 'Alemanya',
'DJ' => 'Djibouti',
'DM' => 'Dominica',
'DK' => 'Dinamarca',
'DO' => 'República Dominicana',
'DZ' => 'Argelia',
'EC' => 'Equador',
'EG' => 'Egipte',
'ER' => 'Eritrea',
'ES' => 'Espanya',
'EE' => 'Estònia',
'ET' => 'Etiòpia',
'FI' => 'Finlàndia',
'FJ' => 'Fiji',
'FR' => 'França',
'FM' => 'Micronèsia',
'GA' => 'Gabon',
'GB' => 'Regne Unit',
'GE' => 'Geòrgia',
'GH' => 'Ghana',
'GN' => 'Guinea',
'GM' => 'Gàmbia',
'GW' => 'Guinea Bissau',
'GQ' => 'Guinea Equatorial',
'GR' => 'Grècia',
'GD' => 'Granada',
'GT' => 'Guatemala',
'GY' => 'Guaiana',
'HN' => 'Hondures',
'HR' => 'Croàcia',
'HT' => 'Haití',
'HU' => 'Hungria',
'ID' => 'Indonèsia',
'IN' => 'Índia',
'IE' => 'Irlanda',
'IR' => 'Iran',
'IQ' => 'Iraq',
'IS' => 'Islàndia',
'IL' => 'Israel',
'IT' => 'Itàlia',
'JM' => 'Jamaica',
'JO' => 'Jordà',
'JP' => 'Japó',
'KZ' => 'Kazakhstan',
'KE' => 'Kenya',
'KG' => 'Kirguizistan',
'KH' => 'Cambodja',
'KI' => 'Kiribati',
'KN' => 'Sant Cristòfol i Neus',
'KR' => 'Corea del Sud',
'KW' => 'Kuwait',
'LA' => 'Laos',
'LB' => 'Líban',
'LR' => 'Libèria',
'LY' => 'Líbia',
'LC' => 'Santa Llúcia',
'LI' => 'Liechtenstein',
'LK' => 'Sri Lanka',
'LS' => 'Lesoto',
'LT' => 'Lituània',
'LU' => 'Luxemburg',
'LV' => 'Letònia',
'MA' => 'Marroc',
'MC' => 'Mònaco',
'MD' => 'Moldàvia',
'MG' => 'Madagascar',
'MV' => 'Maldives',
'MX' => 'Mèxic',
'MH' => 'Illes Marshall',
'MK' => 'Macedònia',
'ML' => 'Mali',
'MT' => 'Malta',
'MM' => 'Myanmar',
'ME' => 'Montenegro',
'MN' => 'Mongòlia',
'MZ' => 'Moçambic',
'MR' => 'Mauritània',
'MU' => 'Maurici',
'MW' => 'Malawi',
'MY' => 'Malàsia',
'NA' => 'Namíbia',
'NE' => 'Níger',
'NG' => 'Nigèria',
'NI' => 'Nicaragua',
'NL' => 'Països Baixos',
'NO' => 'Noruega',
'NP' => 'Nepal',
'NR' => 'Nauru',
'NZ' => 'Nova Zelanda',
'OM' => 'Oman',
'PK' => 'Pakistan',
'PA' => 'Panamà',
'PE' => 'Perú',
'PH' => 'Filipines',
'PW' => 'Palaos',
'PG' => 'Papua Nova Guinea',
'PL' => 'Polònia',
'KP' => 'Corea del Nord',
'PT' => 'Portugal',
'PY' => 'Paraguai',
'QA' => 'Katar',
'RO' => 'Romania',
'RU' => 'Rússia',
'RW' => 'Rwanda',
'SA' => 'Aràbia Saudita',
'SD' => 'Sudan',
'SN' => 'Senegal',
'SG' => 'Singapur',
'SB' => 'Illes Salomó',
'SL' => 'Sierra Leone',
'SV' => 'El Salvador',
'SM' => 'San Marí',
'SO' => 'Somàlia',
'RS' => 'Sèrbia',
'SS' => 'Sudàn del Sud',
'ST' => 'Santo Tomé y Príncipe',
'SR' => 'Surinam',
'SK' => 'Eslovàquia',
'SI' => 'Eslovènia',
'SE' => 'Suècia',
'SZ' => 'Swazilàndia',
'SC' => 'Seychelles',
'SY' => 'Síria',
'TD' => 'Txad',
'TG' => 'Togo',
'TH' => 'Tailàndia',
'TJ' => 'Tadjikistan',
'TM' => 'Turkmenistan',
'TL' => 'Timor Oriental',
'TO' => 'Tonga',
'TT' => 'Trinitat i Tobago',
'TN' => 'Tunísia',
'TR' => 'Turquia',
'TV' => 'Tuvalu',
'TZ' => 'Tanzània',
'UG' => 'Uganda',
'UA' => 'Ucraïna',
'UY' => 'Uruguai',
'US' => 'Estats Units',
'UZ' => 'Uzbekistan',
'VA' => 'Ciudat del Vaticà',
'VC' => 'Saint Vincent i les Grenadines',
'VE' => 'Veneçuela',
'VN' => 'Vietnam',
'VU' => 'Vanuatu',
'WS' => 'Samoa',
'YE' => 'Iemen',
'ZA' => 'Sud-àfrica',
'ZM' => 'Zàmbia',
'ZW' => 'Zimbabwe',
];
<?php
return [
'AF' => 'Afganistan',
'AO' => 'Angola',
'AL' => 'Albània',
'AD' => 'Andorra',
'AE' => 'Unió dels Emirats Àrabs Units',
'AR' => 'Argentina',
'AM' => 'Armènia',
'AG' => 'Antigua o Barbuda',
'AU' => 'Austràlia',
'AT' => 'Àustria',
'AZ' => 'Azerbaidjan',
'BI' => 'Burundi',
'BE' => 'Bèlgica',
'BJ' => 'Benín',
'BF' => 'Burkina Faso',
'BD' => 'Bangla Desh',
'BG' => 'Bulgaria',
'BH' => 'Bahrain',
'BS' => 'Bahamas',
'BA' => 'Bòsnia i Hercegovina',
'BY' => 'Bielorússia',
'BZ' => 'Belize',
'BO' => 'Bolívia',
'BR' => 'Brasil',
'BB' => 'Barbados',
'BN' => 'Brunei',
'BT' => 'Bhutan',
'BW' => 'Botswana',
'CF' => 'República Centreafricana',
'CA' => 'Canadà',
'CH' => 'Suïssa',
'CL' => 'Xile',
'CN' => 'Xina',
'CI' => 'Costa d\'Ivori',
'CM' => 'Camerun',
'CD' => 'República Democràtica del Congo',
'CG' => 'República del congo',
'CO' => 'Colòmbia',
'KM' => 'Comores',
'CV' => 'Cap Verd',
'CR' => 'Costa Rica',
'CU' => 'Cuba',
'CY' => 'Xipre',
'CZ' => 'Txèquia',
'DE' => 'Alemanya',
'DJ' => 'Djibouti',
'DM' => 'Dominica',
'DK' => 'Dinamarca',
'DO' => 'República Dominicana',
'DZ' => 'Argelia',
'EC' => 'Equador',
'EG' => 'Egipte',
'ER' => 'Eritrea',
'ES' => 'Espanya',
'EE' => 'Estònia',
'ET' => 'Etiòpia',
'FI' => 'Finlàndia',
'FJ' => 'Fiji',
'FR' => 'França',
'FM' => 'Micronèsia',
'GA' => 'Gabon',
'GB' => 'Regne Unit',
'GE' => 'Geòrgia',
'GH' => 'Ghana',
'GN' => 'Guinea',
'GM' => 'Gàmbia',
'GW' => 'Guinea Bissau',
'GQ' => 'Guinea Equatorial',
'GR' => 'Grècia',
'GD' => 'Granada',
'GT' => 'Guatemala',
'GY' => 'Guaiana',
'HN' => 'Hondures',
'HR' => 'Croàcia',
'HT' => 'Haití',
'HU' => 'Hungria',
'ID' => 'Indonèsia',
'IN' => 'Índia',
'IE' => 'Irlanda',
'IR' => 'Iran',
'IQ' => 'Iraq',
'IS' => 'Islàndia',
'IL' => 'Israel',
'IT' => 'Itàlia',
'JM' => 'Jamaica',
'JO' => 'Jordà',
'JP' => 'Japó',
'KZ' => 'Kazakhstan',
'KE' => 'Kenya',
'KG' => 'Kirguizistan',
'KH' => 'Cambodja',
'KI' => 'Kiribati',
'KN' => 'Sant Cristòfol i Neus',
'KR' => 'Corea del Sud',
'KW' => 'Kuwait',
'LA' => 'Laos',
'LB' => 'Líban',
'LR' => 'Libèria',
'LY' => 'Líbia',
'LC' => 'Santa Llúcia',
'LI' => 'Liechtenstein',
'LK' => 'Sri Lanka',
'LS' => 'Lesoto',
'LT' => 'Lituània',
'LU' => 'Luxemburg',
'LV' => 'Letònia',
'MA' => 'Marroc',
'MC' => 'Mònaco',
'MD' => 'Moldàvia',
'MG' => 'Madagascar',
'MV' => 'Maldives',
'MX' => 'Mèxic',
'MH' => 'Illes Marshall',
'MK' => 'Macedònia',
'ML' => 'Mali',
'MT' => 'Malta',
'MM' => 'Myanmar',
'ME' => 'Montenegro',
'MN' => 'Mongòlia',
'MZ' => 'Moçambic',
'MR' => 'Mauritània',
'MU' => 'Maurici',
'MW' => 'Malawi',
'MY' => 'Malàsia',
'NA' => 'Namíbia',
'NE' => 'Níger',
'NG' => 'Nigèria',
'NI' => 'Nicaragua',
'NL' => 'Països Baixos',
'NO' => 'Noruega',
'NP' => 'Nepal',
'NR' => 'Nauru',
'NZ' => 'Nova Zelanda',
'OM' => 'Oman',
'PK' => 'Pakistan',
'PA' => 'Panamà',
'PE' => 'Perú',
'PH' => 'Filipines',
'PW' => 'Palaos',
'PG' => 'Papua Nova Guinea',
'PL' => 'Polònia',
'KP' => 'Corea del Nord',
'PT' => 'Portugal',
'PY' => 'Paraguai',
'QA' => 'Katar',
'RO' => 'Romania',
'RU' => 'Rússia',
'RW' => 'Rwanda',
'SA' => 'Aràbia Saudita',
'SD' => 'Sudan',
'SN' => 'Senegal',
'SG' => 'Singapur',
'SB' => 'Illes Salomó',
'SL' => 'Sierra Leone',
'SV' => 'El Salvador',
'SM' => 'San Marí',
'SO' => 'Somàlia',
'RS' => 'Sèrbia',
'SS' => 'Sudàn del Sud',
'ST' => 'Santo Tomé y Príncipe',
'SR' => 'Surinam',
'SK' => 'Eslovàquia',
'SI' => 'Eslovènia',
'SE' => 'Suècia',
'SZ' => 'Swazilàndia',
'SC' => 'Seychelles',
'SY' => 'Síria',
'TD' => 'Txad',
'TG' => 'Togo',
'TH' => 'Tailàndia',
'TJ' => 'Tadjikistan',
'TM' => 'Turkmenistan',
'TL' => 'Timor Oriental',
'TO' => 'Tonga',
'TT' => 'Trinitat i Tobago',
'TN' => 'Tunísia',
'TR' => 'Turquia',
'TV' => 'Tuvalu',
'TZ' => 'Tanzània',
'UG' => 'Uganda',
'UA' => 'Ucraïna',
'UY' => 'Uruguai',
'US' => 'Estats Units',
'UZ' => 'Uzbekistan',
'VA' => 'Ciudat del Vaticà',
'VC' => 'Saint Vincent i les Grenadines',
'VE' => 'Veneçuela',
'VN' => 'Vietnam',
'VU' => 'Vanuatu',
'WS' => 'Samoa',
'YE' => 'Iemen',
'ZA' => 'Sud-àfrica',
'ZM' => 'Zàmbia',
'ZW' => 'Zimbabwe',
];

View file

@ -1,21 +1,21 @@
<?php
return [
'settings.inspire' => '"L\'art de ser sabi és l\'art de saber què passar per alt"', // This is the line printed in the homepage and console 'view-source'
'settings.locale' => 'cat',
'settings.direction' => 'ltr',
// Service - Users
'auth.emails.team' => '%s Equip',
'auth.emails.confirm.title' => 'Confirmació del compte',
'auth.emails.confirm.body' => 'cat.email.auth.confirm.tpl',
'auth.emails.recovery.title' => 'Restablir contrasenya',
'auth.emails.recovery.body' => 'cat.email.auth.recovery.tpl',
'auth.emails.invitation.title' => 'Invitació a l\'Equipo %s a %s',
'auth.emails.invitation.body' => 'cat.email.auth.invitation.tpl',
'locale.country.unknown' => 'Desconegut',
'countries' => include 'cat.countries.php',
'continents' => include 'cat.continents.php',
];
<?php
return [
'settings.inspire' => '"L\'art de ser sabi és l\'art de saber què passar per alt"', // This is the line printed in the homepage and console 'view-source'
'settings.locale' => 'cat',
'settings.direction' => 'ltr',
// Service - Users
'auth.emails.team' => '%s Equip',
'auth.emails.confirm.title' => 'Confirmació del compte',
'auth.emails.confirm.body' => 'cat.email.auth.confirm.tpl',
'auth.emails.recovery.title' => 'Restablir contrasenya',
'auth.emails.recovery.body' => 'cat.email.auth.recovery.tpl',
'auth.emails.invitation.title' => 'Invitació a l\'Equipo %s a %s',
'auth.emails.invitation.body' => 'cat.email.auth.invitation.tpl',
'locale.country.unknown' => 'Desconegut',
'countries' => include 'cat.countries.php',
'continents' => include 'cat.continents.php',
];

View file

@ -8,4 +8,4 @@ return [
'NA' => 'Pohjois Amerikka',
'OC' => 'Oceania',
'SA' => 'Etelä Amerikka',
];
];

View file

@ -195,4 +195,4 @@ return [
'ZA' => 'Etelä-Afrikka',
'ZM' => 'Sambia',
'ZW' => 'Zimbabwe',
];
];

View file

@ -18,4 +18,4 @@ return [
'countries' => include 'fi.countries.php',
'continents' => include 'fi.continents.php',
];
];

View file

@ -18,4 +18,4 @@ return [
'countries' => include 'nl.countries.php',
'continents' => include 'nl.continents.php',
];
];

View file

@ -1,198 +1,198 @@
<?php
return [
'AF' => 'Afganistan',
'AO' => 'Angola',
'AL' => 'Arnavutluk',
'AD' => 'Andorra',
'AE' => 'Birleşik Arap Emirlikleri',
'AR' => 'Arjantin',
'AM' => 'Ermenistan',
'AG' => 'Antigua ve Barbuda',
'AU' => 'Avustralya',
'AT' => 'Avusturya',
'AZ' => 'Azerbaycan',
'BI' => 'Burundi',
'BE' => 'Belçika',
'BJ' => 'Benin',
'BF' => 'Burkina Faso',
'BD' => 'Bangladeş',
'BG' => 'Bulgaristan',
'BH' => 'Bahreyn',
'BS' => 'Bahamalar',
'BA' => 'Bosna Hersek',
'BY' => 'Beyaz Rusya',
'BZ' => 'Belize',
'BO' => 'Bolivya',
'BR' => 'Brezilya',
'BB' => 'Barbados',
'BN' => 'Brunei',
'BT' => 'Butan',
'BW' => 'Botsvana',
'CF' => 'Orta Afrika Cumhuriyeti',
'CA' => 'Kanada',
'CH' => 'İsviçre',
'CL' => 'Şili',
'CN' => 'Çin',
'CI' => 'Fildişi Sahili',
'CM' => 'Kamerun',
'CD' => 'Kongo - Kinşasa',
'CG' => 'Kongo - Brazavil',
'CO' => 'Kolombiya',
'KM' => 'Komorlar',
'CV' => 'Cape Verde',
'CR' => 'Kosta Rika',
'CU' => 'Küba',
'CY' => 'Güney Kıbrıs Rum Kesimi',
'CZ' => 'Çek Cumhuriyeti',
'DE' => 'Almanya',
'DJ' => 'Cibuti',
'DM' => 'Dominika',
'DK' => 'Danimarka',
'DO' => 'Dominik Cumhuriyeti',
'DZ' => 'Cezayir',
'EC' => 'Ekvador',
'EG' => 'Mısır',
'ER' => 'Eritre',
'ES' => 'İspanya',
'EE' => 'Estonya',
'ET' => 'Etiyopya',
'FI' => 'Finlandiya',
'FJ' => 'Fiji',
'FR' => 'Fransa',
'FM' => 'Mikronezya',
'GA' => 'Gabon',
'GB' => 'Birleşik Krallık',
'GE' => 'Gürcistan',
'GH' => 'Gana',
'GN' => 'Gine',
'GM' => 'Gambiya',
'GW' => 'Gine-Bissau',
'GQ' => 'Ekvator Ginesi',
'GR' => 'Yunanistan',
'GD' => 'Grenada',
'GT' => 'Guatemala',
'GY' => 'Guyana',
'HN' => 'Honduras',
'HR' => 'Hırvatistan',
'HT' => 'Haiti',
'HU' => 'Macaristan',
'ID' => 'Endonezya',
'IN' => 'Hindistan',
'IE' => 'İrlanda',
'IR' => 'İran',
'IQ' => 'Irak',
'IS' => 'İzlanda',
'IL' => 'İsrail',
'IT' => 'İtalya',
'JM' => 'Jamaika',
'JO' => 'Ürdün',
'JP' => 'Japonya',
'KZ' => 'Kazakistan',
'KE' => 'Kenya',
'KG' => 'Kırgızistan',
'KH' => 'Kamboçya',
'KI' => 'Kiribati',
'KN' => 'Saint Kitts ve Nevis',
'KR' => 'Güney Kore',
'KW' => 'Kuveyt',
'LA' => 'Laos',
'LB' => 'Lübnan',
'LR' => 'Liberya',
'LY' => 'Libya',
'LC' => 'Saint Lucia',
'LI' => 'Liechtenstein',
'LK' => 'Sri Lanka',
'LS' => 'Lesoto',
'LT' => 'Litvanya',
'LU' => 'Lüksemburg',
'LV' => 'Letonya',
'MA' => 'Fas',
'MC' => 'Monako',
'MD' => 'Moldova',
'MG' => 'Madagaskar',
'MV' => 'Maldivler',
'MX' => 'Meksika',
'MH' => 'Marshall Adaları',
'MK' => 'Makedonya',
'ML' => 'Mali',
'MT' => 'Malta',
'MM' => 'Myanmar (Burma)',
'ME' => 'Karadağ',
'MN' => 'Moğolistan',
'MZ' => 'Mozambik',
'MR' => 'Moritanya',
'MU' => 'Mauritius',
'MW' => 'Malavi',
'MY' => 'Malezya',
'NA' => 'Namibya',
'NE' => 'Nijer',
'NG' => 'Nijerya',
'NI' => 'Nikaragua',
'NL' => 'Hollanda',
'NO' => 'Norveç',
'NP' => 'Nepal',
'NR' => 'Nauru',
'NZ' => 'Yeni Zelanda',
'OM' => 'Umman',
'PK' => 'Pakistan',
'PA' => 'Panama',
'PE' => 'Peru',
'PH' => 'Filipinler',
'PW' => 'Palau',
'PG' => 'Papua Yeni Gine',
'PL' => 'Polonya',
'KP' => 'Kuzey Kore',
'PT' => 'Portekiz',
'PY' => 'Paraguay',
'QA' => 'Katar',
'RO' => 'Romanya',
'RU' => 'Rusya',
'RW' => 'Ruanda',
'SA' => 'Suudi Arabistan',
'SD' => 'Sudan',
'SN' => 'Senegal',
'SG' => 'Singapur',
'SB' => 'Solomon Adaları',
'SL' => 'Sierra Leone',
'SV' => 'El Salvador',
'SM' => 'San Marino',
'SO' => 'Somali',
'RS' => 'Sırbistan',
'SS' => 'Güney Sudan',
'ST' => 'São Tomé ve Príncipe',
'SR' => 'Surinam',
'SK' => 'Slovakya',
'SI' => 'Slovenya',
'SE' => 'İsveç',
'SZ' => 'Svaziland',
'SC' => 'Seyşeller',
'SY' => 'Suriye',
'TD' => 'Çad',
'TG' => 'Togo',
'TH' => 'Tayland',
'TJ' => 'Tacikistan',
'TM' => 'Türkmenistan',
'TL' => 'Timor-Leste',
'TO' => 'Tonga',
'TT' => 'Trinidad ve Tobago',
'TN' => 'Tunus',
'TR' => 'Türkiye',
'TV' => 'Tuvalu',
'TZ' => 'Tanzanya',
'UG' => 'Uganda',
'UA' => 'Ukrayna',
'UY' => 'Uruguay',
'US' => 'ABD',
'UZ' => 'Özbekistan',
'VA' => 'Vatikan',
'VC' => 'Saint Vincent ve Grenadinler',
'VE' => 'Venezuela',
'VN' => 'Vietnam',
'VU' => 'Vanuatu',
'WS' => 'Samoa',
'YE' => 'Yemen',
'ZA' => 'Güney Afrika',
'ZM' => 'Zambiya',
'ZW' => 'Zimbabve',
'AF' => 'Afganistan',
'AO' => 'Angola',
'AL' => 'Arnavutluk',
'AD' => 'Andorra',
'AE' => 'Birleşik Arap Emirlikleri',
'AR' => 'Arjantin',
'AM' => 'Ermenistan',
'AG' => 'Antigua ve Barbuda',
'AU' => 'Avustralya',
'AT' => 'Avusturya',
'AZ' => 'Azerbaycan',
'BI' => 'Burundi',
'BE' => 'Belçika',
'BJ' => 'Benin',
'BF' => 'Burkina Faso',
'BD' => 'Bangladeş',
'BG' => 'Bulgaristan',
'BH' => 'Bahreyn',
'BS' => 'Bahamalar',
'BA' => 'Bosna Hersek',
'BY' => 'Beyaz Rusya',
'BZ' => 'Belize',
'BO' => 'Bolivya',
'BR' => 'Brezilya',
'BB' => 'Barbados',
'BN' => 'Brunei',
'BT' => 'Butan',
'BW' => 'Botsvana',
'CF' => 'Orta Afrika Cumhuriyeti',
'CA' => 'Kanada',
'CH' => 'İsviçre',
'CL' => 'Şili',
'CN' => 'Çin',
'CI' => 'Fildişi Sahili',
'CM' => 'Kamerun',
'CD' => 'Kongo - Kinşasa',
'CG' => 'Kongo - Brazavil',
'CO' => 'Kolombiya',
'KM' => 'Komorlar',
'CV' => 'Cape Verde',
'CR' => 'Kosta Rika',
'CU' => 'Küba',
'CY' => 'Güney Kıbrıs Rum Kesimi',
'CZ' => 'Çek Cumhuriyeti',
'DE' => 'Almanya',
'DJ' => 'Cibuti',
'DM' => 'Dominika',
'DK' => 'Danimarka',
'DO' => 'Dominik Cumhuriyeti',
'DZ' => 'Cezayir',
'EC' => 'Ekvador',
'EG' => 'Mısır',
'ER' => 'Eritre',
'ES' => 'İspanya',
'EE' => 'Estonya',
'ET' => 'Etiyopya',
'FI' => 'Finlandiya',
'FJ' => 'Fiji',
'FR' => 'Fransa',
'FM' => 'Mikronezya',
'GA' => 'Gabon',
'GB' => 'Birleşik Krallık',
'GE' => 'Gürcistan',
'GH' => 'Gana',
'GN' => 'Gine',
'GM' => 'Gambiya',
'GW' => 'Gine-Bissau',
'GQ' => 'Ekvator Ginesi',
'GR' => 'Yunanistan',
'GD' => 'Grenada',
'GT' => 'Guatemala',
'GY' => 'Guyana',
'HN' => 'Honduras',
'HR' => 'Hırvatistan',
'HT' => 'Haiti',
'HU' => 'Macaristan',
'ID' => 'Endonezya',
'IN' => 'Hindistan',
'IE' => 'İrlanda',
'IR' => 'İran',
'IQ' => 'Irak',
'IS' => 'İzlanda',
'IL' => 'İsrail',
'IT' => 'İtalya',
'JM' => 'Jamaika',
'JO' => 'Ürdün',
'JP' => 'Japonya',
'KZ' => 'Kazakistan',
'KE' => 'Kenya',
'KG' => 'Kırgızistan',
'KH' => 'Kamboçya',
'KI' => 'Kiribati',
'KN' => 'Saint Kitts ve Nevis',
'KR' => 'Güney Kore',
'KW' => 'Kuveyt',
'LA' => 'Laos',
'LB' => 'Lübnan',
'LR' => 'Liberya',
'LY' => 'Libya',
'LC' => 'Saint Lucia',
'LI' => 'Liechtenstein',
'LK' => 'Sri Lanka',
'LS' => 'Lesoto',
'LT' => 'Litvanya',
'LU' => 'Lüksemburg',
'LV' => 'Letonya',
'MA' => 'Fas',
'MC' => 'Monako',
'MD' => 'Moldova',
'MG' => 'Madagaskar',
'MV' => 'Maldivler',
'MX' => 'Meksika',
'MH' => 'Marshall Adaları',
'MK' => 'Makedonya',
'ML' => 'Mali',
'MT' => 'Malta',
'MM' => 'Myanmar (Burma)',
'ME' => 'Karadağ',
'MN' => 'Moğolistan',
'MZ' => 'Mozambik',
'MR' => 'Moritanya',
'MU' => 'Mauritius',
'MW' => 'Malavi',
'MY' => 'Malezya',
'NA' => 'Namibya',
'NE' => 'Nijer',
'NG' => 'Nijerya',
'NI' => 'Nikaragua',
'NL' => 'Hollanda',
'NO' => 'Norveç',
'NP' => 'Nepal',
'NR' => 'Nauru',
'NZ' => 'Yeni Zelanda',
'OM' => 'Umman',
'PK' => 'Pakistan',
'PA' => 'Panama',
'PE' => 'Peru',
'PH' => 'Filipinler',
'PW' => 'Palau',
'PG' => 'Papua Yeni Gine',
'PL' => 'Polonya',
'KP' => 'Kuzey Kore',
'PT' => 'Portekiz',
'PY' => 'Paraguay',
'QA' => 'Katar',
'RO' => 'Romanya',
'RU' => 'Rusya',
'RW' => 'Ruanda',
'SA' => 'Suudi Arabistan',
'SD' => 'Sudan',
'SN' => 'Senegal',
'SG' => 'Singapur',
'SB' => 'Solomon Adaları',
'SL' => 'Sierra Leone',
'SV' => 'El Salvador',
'SM' => 'San Marino',
'SO' => 'Somali',
'RS' => 'Sırbistan',
'SS' => 'Güney Sudan',
'ST' => 'São Tomé ve Príncipe',
'SR' => 'Surinam',
'SK' => 'Slovakya',
'SI' => 'Slovenya',
'SE' => 'İsveç',
'SZ' => 'Svaziland',
'SC' => 'Seyşeller',
'SY' => 'Suriye',
'TD' => 'Çad',
'TG' => 'Togo',
'TH' => 'Tayland',
'TJ' => 'Tacikistan',
'TM' => 'Türkmenistan',
'TL' => 'Timor-Leste',
'TO' => 'Tonga',
'TT' => 'Trinidad ve Tobago',
'TN' => 'Tunus',
'TR' => 'Türkiye',
'TV' => 'Tuvalu',
'TZ' => 'Tanzanya',
'UG' => 'Uganda',
'UA' => 'Ukrayna',
'UY' => 'Uruguay',
'US' => 'ABD',
'UZ' => 'Özbekistan',
'VA' => 'Vatikan',
'VC' => 'Saint Vincent ve Grenadinler',
'VE' => 'Venezuela',
'VN' => 'Vietnam',
'VU' => 'Vanuatu',
'WS' => 'Samoa',
'YE' => 'Yemen',
'ZA' => 'Güney Afrika',
'ZM' => 'Zambiya',
'ZW' => 'Zimbabve',
];

View file

@ -7,4 +7,4 @@
'NA' => 'Північна Америка',
'OC' => 'Океанія',
'SA' => 'Південна Америка',
];
];

View file

@ -194,4 +194,4 @@
'ZA' => 'Південна Африка',
'ZM' => 'Замбія',
'ZW' => 'Зімбабве',
];
];

View file

@ -4,7 +4,7 @@ return [
'bitbucket' => [
'developers' => 'https://developer.atlassian.com/bitbucket',
'icon' => 'icon-bitbucket',
'enabled' => false,
'enabled' => true,
],
'facebook' => [
'developers' => 'https://developers.facebook.com/',

View file

@ -1,4 +1,3 @@
<?php
global $utopia, $register, $request, $response, $user, $audit, $webhook, $project, $domain, $projectDB, $providers, $clients;
@ -49,9 +48,9 @@ $utopia->post('/v1/auth/register')
->action(
function ($email, $password, $confirm, $success, $failure, $name) use ($request, $response, $register, $audit, $projectDB, $project, $webhook) {
if ('console' === $project->getUid()) {
$whitlistEmails = $project->getAttribute('authWhitelistEmails');
$whitlistIPs = $project->getAttribute('authWhitelistIPs');
$whitlistDomains = $project->getAttribute('authWhitelistDomains');
$whitlistEmails = $project->getAttribute('authWhitelistEmails');
$whitlistIPs = $project->getAttribute('authWhitelistIPs');
$whitlistDomains = $project->getAttribute('authWhitelistDomains');
if (!empty($whitlistEmails) && !in_array($email, $whitlistEmails)) {
throw new Exception('Console registration is restricted to specific emails. Contact your administrator for more information.', 401);
@ -61,11 +60,11 @@ $utopia->post('/v1/auth/register')
throw new Exception('Console registration is restricted to specific IPs. Contact your administrator for more information.', 401);
}
if (!empty($whitlistDomains) && !in_array(substr(strrchr($email, '@'), 1), $whitlistDomains)) {
if (!empty($whitlistDomains) && !in_array(substr(strrchr($email, "@"), 1), $whitlistDomains)) {
throw new Exception('Console registration is restricted to specific domains. Contact your administrator for more information.', 401);
}
}
$profile = $projectDB->getCollection([ // Get user by email address
'limit' => 1,
'first' => true,
@ -77,7 +76,7 @@ $utopia->post('/v1/auth/register')
if (!empty($profile)) {
if ($failure) {
$response->redirect($failure.'?message=User already registered');
$response->redirect($failure . '?message=User already registered');
return;
}
@ -778,7 +777,7 @@ $utopia->get('/v1/auth/oauth/:provider/redirect')
}
$oauthID = $oauth->getUserID($accessToken);
if (empty($oauthID)) {
if (!empty($state['failure'])) {
$response->redirect($state['failure'], 301, 0);
@ -788,7 +787,7 @@ $utopia->get('/v1/auth/oauth/:provider/redirect')
}
$current = Auth::tokenVerify($user->getAttribute('tokens', []), Auth::TOKEN_TYPE_LOGIN, Auth::$secret);
if ($current) {
$projectDB->deleteDocument($current); //throw new Exception('User already logged in', 401);
}
@ -802,6 +801,7 @@ $utopia->get('/v1/auth/oauth/:provider/redirect')
],
]) : $user;
if (empty($user)) { // No user logged in or with oauth provider ID, create new one or connect with account with same email
$name = $oauth->getUserName($accessToken);
$email = $oauth->getUserEmail($accessToken);

View file

@ -31,7 +31,7 @@ Once you have finished setting up all the metadata for the new provider, you nee
Create a new class that extends the basic OAuth provider abstract class in this location:
```bash
src/Auth/OAuth/ProviderName
./src/Auth/OAuth/ProviderName
```
Note that the class name should start with a capital letter as PHP FIG standards suggest.

Binary file not shown.

After

Width:  |  Height:  |  Size: 14 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 716 KiB

After

Width:  |  Height:  |  Size: 6.7 KiB

View file

@ -0,0 +1,132 @@
<?php
namespace Auth\OAuth;
use Auth\OAuth;
// Reference Material
// https://confluence.atlassian.com/bitbucket/oauth-on-bitbucket-cloud-238027431.html#OAuthonBitbucketCloud-Createaconsumer
class Bitbucket extends OAuth
{
/**
* @var array
*/
protected $user = [];
/**
* @return string
*/
public function getName(): string
{
return 'bitbucket';
}
/**
* @return string
*/
public function getLoginURL(): string
{
return 'https://bitbucket.org/site/oauth2/authorize?' .
'client_id=' . urlencode($this->appID).
'&state=' . urlencode(json_encode($this->state)).
'&response_type=code';
}
/**
* @param string $code
*
* @return string
*/
public function getAccessToken(string $code): string
{
// Required as per Bitbucket Spec.
$headers[] = 'Content-Type: application/x-www-form-urlencoded';
$accessToken = $this->request(
'POST',
'https://bitbucket.org/site/oauth2/access_token',
$headers,
'code=' . urlencode($code) .
'&client_id=' . urlencode($this->appID) .
'&client_secret=' . urlencode($this->appSecret).
'&grant_type=authorization_code'
);
$accessToken = json_decode($accessToken, true);
if (isset($accessToken['access_token'])) {
return $accessToken['access_token'];
}
return '';
}
/**
* @param string $accessToken
*
* @return string
*/
public function getUserID(string $accessToken): string
{
$user = $this->getUser($accessToken);
if (isset($user['uuid'])) {
return $user['uuid'];
}
return '';
}
/**
* @param string $accessToken
*
* @return string
*/
public function getUserEmail(string $accessToken): string
{
$user = $this->getUser($accessToken);
if (isset($user['email'])) {
return $user['email'];
}
return '';
}
/**
* @param string $accessToken
*
* @return string
*/
public function getUserName(string $accessToken): string
{
$user = $this->getUser($accessToken);
if (isset($user['display_name'])) {
return $user['display_name'];
}
return '';
}
/**
* @param string $accessToken
*
* @return array
*/
protected function getUser(string $accessToken): array
{
if (empty($this->user)) {
$user = $this->request('GET', 'https://api.bitbucket.org/2.0/user?access_token='.urlencode($accessToken));
$this->user = json_decode($user, true);
$email = $this->request('GET', 'https://api.bitbucket.org/2.0/user/emails?access_token='.urlencode($accessToken));
$this->user['email'] = json_decode($email, true)['values'][0]['email'];
// var_dump($user);
// exit();
}
return $this->user;
}
}