diff --git a/composer.json b/composer.json
index 3716ec67..f93f66b3 100644
--- a/composer.json
+++ b/composer.json
@@ -62,7 +62,8 @@
"ramsey/array_column": "~1.1",
"propel/propel": "dev-thelia-2.3",
"commerceguys/addressing": "0.8.*",
- "thelia/paypal-module": "~3.0.0"
+ "thelia/paypal-module": "~3.0.0",
+ "giggsey/libphonenumber-for-php": "^8.1.3"
},
"require-dev": {
"fzaninotto/faker": "1.5.*",
diff --git a/composer.lock b/composer.lock
index 9c1e0d36..89e862ff 100644
--- a/composer.lock
+++ b/composer.lock
@@ -1,10 +1,10 @@
{
"_readme": [
"This file locks the dependencies of your project to a known state",
- "Read more about it at https://getcomposer.org/doc/01-basic-usage.md#composer-lock-the-lock-file",
+ "Read more about it at https://getcomposer.org/doc/01-basic-usage.md#installing-dependencies",
"This file is @generated automatically"
],
- "content-hash": "8fbc68f5bab568a5ff0999a67a6fef4f",
+ "content-hash": "9adcc003d8cd7a382d5fedd229b5e860",
"packages": [
{
"name": "commerceguys/addressing",
@@ -349,17 +349,134 @@
"abandoned": "tecnickcom/tcpdf",
"time": "2013-09-12T17:00:40+00:00"
},
+ {
+ "name": "giggsey/libphonenumber-for-php",
+ "version": "8.12.4",
+ "source": {
+ "type": "git",
+ "url": "https://github.com/giggsey/libphonenumber-for-php.git",
+ "reference": "cb79970730aacaedb74c8288214a5576572fa7b0"
+ },
+ "dist": {
+ "type": "zip",
+ "url": "https://api.github.com/repos/giggsey/libphonenumber-for-php/zipball/cb79970730aacaedb74c8288214a5576572fa7b0",
+ "reference": "cb79970730aacaedb74c8288214a5576572fa7b0",
+ "shasum": ""
+ },
+ "require": {
+ "ext-mbstring": "*",
+ "giggsey/locale": "^1.7",
+ "php": ">=5.3.2"
+ },
+ "require-dev": {
+ "pear/pear-core-minimal": "^1.9",
+ "pear/pear_exception": "^1.0",
+ "pear/versioncontrol_git": "^0.5",
+ "phing/phing": "^2.7",
+ "php-coveralls/php-coveralls": "^1.0|^2.0",
+ "phpunit/phpunit": "^4.8.36|^5.0",
+ "symfony/console": "^2.8|^3.0"
+ },
+ "type": "library",
+ "extra": {
+ "branch-alias": {
+ "dev-master": "8.x-dev"
+ }
+ },
+ "autoload": {
+ "psr-4": {
+ "libphonenumber\\": "src/"
+ },
+ "exclude-from-classmap": [
+ "/src/data/",
+ "/src/carrier/data/",
+ "/src/geocoding/data/",
+ "/src/timezone/data/"
+ ]
+ },
+ "notification-url": "https://packagist.org/downloads/",
+ "license": [
+ "Apache-2.0"
+ ],
+ "authors": [
+ {
+ "name": "Joshua Gigg",
+ "email": "giggsey@gmail.com",
+ "homepage": "https://giggsey.com/"
+ }
+ ],
+ "description": "PHP Port of Google's libphonenumber",
+ "homepage": "https://github.com/giggsey/libphonenumber-for-php",
+ "keywords": [
+ "geocoding",
+ "geolocation",
+ "libphonenumber",
+ "mobile",
+ "phonenumber",
+ "validation"
+ ],
+ "time": "2020-05-19T11:20:54+00:00"
+ },
+ {
+ "name": "giggsey/locale",
+ "version": "1.9",
+ "source": {
+ "type": "git",
+ "url": "https://github.com/giggsey/Locale.git",
+ "reference": "b07f1eace8072ccc61445ad8fbd493ff9d783043"
+ },
+ "dist": {
+ "type": "zip",
+ "url": "https://api.github.com/repos/giggsey/Locale/zipball/b07f1eace8072ccc61445ad8fbd493ff9d783043",
+ "reference": "b07f1eace8072ccc61445ad8fbd493ff9d783043",
+ "shasum": ""
+ },
+ "require": {
+ "php": ">=5.3.2"
+ },
+ "require-dev": {
+ "pear/pear-core-minimal": "^1.9",
+ "pear/pear_exception": "^1.0",
+ "pear/versioncontrol_git": "^0.5",
+ "phing/phing": "~2.7",
+ "php-coveralls/php-coveralls": "^1.0|^2.0",
+ "phpunit/phpunit": "^4.8|^5.0",
+ "symfony/console": "^2.8|^3.0|^4.0",
+ "symfony/filesystem": "^2.8|^3.0|^4.0",
+ "symfony/finder": "^2.8|^3.0|^4.0",
+ "symfony/process": "^2.8|^3.0|^4.0"
+ },
+ "type": "library",
+ "autoload": {
+ "psr-4": {
+ "Giggsey\\Locale\\": "src/"
+ }
+ },
+ "notification-url": "https://packagist.org/downloads/",
+ "license": [
+ "MIT"
+ ],
+ "authors": [
+ {
+ "name": "Joshua Gigg",
+ "email": "giggsey@gmail.com",
+ "homepage": "http://giggsey.com/"
+ }
+ ],
+ "description": "Locale functions required by libphonenumber-for-php",
+ "time": "2020-07-07T11:16:24+00:00"
+ },
{
"name": "imagine/imagine",
"version": "v0.6.3",
"source": {
"type": "git",
- "url": "https://github.com/avalanche123/Imagine.git",
+ "url": "https://github.com/php-imagine/Imagine.git",
"reference": "149041d2a1b517107bfe270ca2b1a17aa341715d"
},
"dist": {
"type": "zip",
- "url": "https://api.github.com/repos/avalanche123/Imagine/zipball/149041d2a1b517107bfe270ca2b1a17aa341715d",
+ "url": "https://api.github.com/repos/php-imagine/Imagine/zipball/149041d2a1b517107bfe270ca2b1a17aa341715d",
"reference": "149041d2a1b517107bfe270ca2b1a17aa341715d",
"shasum": ""
},
@@ -714,6 +831,7 @@
"php",
"stylesheet"
],
+ "abandoned": true,
"time": "2015-12-30T05:47:36+00:00"
},
{
@@ -811,6 +929,7 @@
"rest",
"sdk"
],
+ "abandoned": true,
"time": "2016-04-22T03:29:29+00:00"
},
{
@@ -1001,6 +1120,7 @@
"array_column",
"column"
],
+ "abandoned": "it-for-free/array_column",
"time": "2015-03-20T22:07:39+00:00"
},
{
@@ -1159,6 +1279,7 @@
"keywords": [
"stack"
],
+ "abandoned": true,
"time": "2014-11-23T20:37:11+00:00"
},
{
@@ -1212,6 +1333,7 @@
"mail",
"mailer"
],
+ "abandoned": "symfony/mailer",
"time": "2015-06-06T14:19:39+00:00"
},
{
@@ -1378,6 +1500,7 @@
],
"description": "Symfony ClassLoader Component",
"homepage": "https://symfony.com",
+ "abandoned": true,
"time": "2016-01-03T15:33:41+00:00"
},
{
@@ -1545,6 +1668,7 @@
],
"description": "Symfony Debug Component",
"homepage": "https://symfony.com",
+ "abandoned": "symfony/error-handler",
"time": "2016-01-13T10:28:07+00:00"
},
{
@@ -2916,6 +3040,7 @@
],
"description": "Symfony Security Component",
"homepage": "https://symfony.com",
+ "abandoned": true,
"time": "2016-01-14T09:10:32+00:00"
},
{
@@ -4450,5 +4575,6 @@
"platform": {
"php": ">=5.4"
},
- "platform-dev": []
+ "platform-dev": [],
+ "plugin-api-version": "1.1.0"
}
diff --git a/composer.phar b/composer.phar
old mode 100755
new mode 100644
index 508f9cf2..49a52306
Binary files a/composer.phar and b/composer.phar differ
diff --git a/local/modules/Paybox/.github/workflows/release.yml b/local/modules/Paybox/.github/workflows/release.yml
new file mode 100644
index 00000000..e8801405
--- /dev/null
+++ b/local/modules/Paybox/.github/workflows/release.yml
@@ -0,0 +1,7 @@
+name: "Auto Release"
+on:
+ push:
+ branches: [ master, main ]
+jobs:
+ release:
+ uses: thelia-modules/ReusableWorkflow/.github/workflows/auto_release.yml@main
diff --git a/local/modules/Paybox/AdminIncludes/_notes/dwsync.xml b/local/modules/Paybox/AdminIncludes/_notes/dwsync.xml
deleted file mode 100644
index 10a92f63..00000000
--- a/local/modules/Paybox/AdminIncludes/_notes/dwsync.xml
+++ /dev/null
@@ -1,4 +0,0 @@
-
-
-
-
\ No newline at end of file
diff --git a/local/modules/Paybox/Config/_notes/dwsync.xml b/local/modules/Paybox/Config/_notes/dwsync.xml
deleted file mode 100644
index c4213585..00000000
--- a/local/modules/Paybox/Config/_notes/dwsync.xml
+++ /dev/null
@@ -1,8 +0,0 @@
-
-
-
-
-
-
-
-
\ No newline at end of file
diff --git a/local/modules/Paybox/Config/iso4217.xml b/local/modules/Paybox/Config/iso4217.xml
index 7e6059bb..03dc5a5c 100644
--- a/local/modules/Paybox/Config/iso4217.xml
+++ b/local/modules/Paybox/Config/iso4217.xml
@@ -1,1949 +1,1944 @@
-
-
-
- AFGHANISTAN
- Afghani
- AFN
- 971
- 2
-
-
- ÅLAND ISLANDS
- Euro
- EUR
- 978
- 2
-
-
- ALBANIA
- Lek
- ALL
- 008
- 2
-
-
- ALGERIA
- Algerian Dinar
- DZD
- 012
- 2
-
-
- AMERICAN SAMOA
- US Dollar
- USD
- 840
- 2
-
-
- ANDORRA
- Euro
- EUR
- 978
- 2
-
-
- ANGOLA
- Kwanza
- AOA
- 973
- 2
-
-
- ANGUILLA
- East Caribbean Dollar
- XCD
- 951
- 2
-
-
- ANTARCTICA
- No universal currency
-
-
- ANTIGUA AND BARBUDA
- East Caribbean Dollar
- XCD
- 951
- 2
-
-
- ARGENTINA
- Argentine Peso
- ARS
- 032
- 2
-
-
- ARMENIA
- Armenian Dram
- AMD
- 051
- 2
-
-
- ARUBA
- Aruban Florin
- AWG
- 533
- 2
-
-
- AUSTRALIA
- Australian Dollar
- AUD
- 036
- 2
-
-
- AUSTRIA
- Euro
- EUR
- 978
- 2
-
-
- AZERBAIJAN
- Azerbaijan Manat
- AZN
- 944
- 2
-
-
- BAHAMAS (THE)
- Bahamian Dollar
- BSD
- 044
- 2
-
-
- BAHRAIN
- Bahraini Dinar
- BHD
- 048
- 3
-
-
- BANGLADESH
- Taka
- BDT
- 050
- 2
-
-
- BARBADOS
- Barbados Dollar
- BBD
- 052
- 2
-
-
- BELARUS
- Belarusian Ruble
- BYN
- 933
- 2
-
-
- BELGIUM
- Euro
- EUR
- 978
- 2
-
-
- BELIZE
- Belize Dollar
- BZD
- 084
- 2
-
-
- BENIN
- CFA Franc BCEAO
- XOF
- 952
- 0
-
-
- BERMUDA
- Bermudian Dollar
- BMD
- 060
- 2
-
-
- BHUTAN
- Indian Rupee
- INR
- 356
- 2
-
-
- BHUTAN
- Ngultrum
- BTN
- 064
- 2
-
-
- BOLIVIA (PLURINATIONAL STATE OF)
- Boliviano
- BOB
- 068
- 2
-
-
- BOLIVIA (PLURINATIONAL STATE OF)
- Mvdol
- BOV
- 984
- 2
-
-
- BONAIRE, SINT EUSTATIUS AND SABA
- US Dollar
- USD
- 840
- 2
-
-
- BOSNIA AND HERZEGOVINA
- Convertible Mark
- BAM
- 977
- 2
-
-
- BOTSWANA
- Pula
- BWP
- 072
- 2
-
-
- BOUVET ISLAND
- Norwegian Krone
- NOK
- 578
- 2
-
-
- BRAZIL
- Brazilian Real
- BRL
- 986
- 2
-
-
- BRITISH INDIAN OCEAN TERRITORY (THE)
- US Dollar
- USD
- 840
- 2
-
-
- BRUNEI DARUSSALAM
- Brunei Dollar
- BND
- 096
- 2
-
-
- BULGARIA
- Bulgarian Lev
- BGN
- 975
- 2
-
-
- BURKINA FASO
- CFA Franc BCEAO
- XOF
- 952
- 0
-
-
- BURUNDI
- Burundi Franc
- BIF
- 108
- 0
-
-
- CABO VERDE
- Cabo Verde Escudo
- CVE
- 132
- 2
-
-
- CAMBODIA
- Riel
- KHR
- 116
- 2
-
-
- CAMEROON
- CFA Franc BEAC
- XAF
- 950
- 0
-
-
- CANADA
- Canadian Dollar
- CAD
- 124
- 2
-
-
- CAYMAN ISLANDS (THE)
- Cayman Islands Dollar
- KYD
- 136
- 2
-
-
- CENTRAL AFRICAN REPUBLIC (THE)
- CFA Franc BEAC
- XAF
- 950
- 0
-
-
- CHAD
- CFA Franc BEAC
- XAF
- 950
- 0
-
-
- CHILE
- Chilean Peso
- CLP
- 152
- 0
-
-
- CHILE
- Unidad de Fomento
- CLF
- 990
- 4
-
-
- CHINA
- Yuan Renminbi
- CNY
- 156
- 2
-
-
- CHRISTMAS ISLAND
- Australian Dollar
- AUD
- 036
- 2
-
-
- COCOS (KEELING) ISLANDS (THE)
- Australian Dollar
- AUD
- 036
- 2
-
-
- COLOMBIA
- Colombian Peso
- COP
- 170
- 2
-
-
- COLOMBIA
- Unidad de Valor Real
- COU
- 970
- 2
-
-
- COMOROS (THE)
- Comorian Franc
- KMF
- 174
- 0
-
-
- CONGO (THE DEMOCRATIC REPUBLIC OF THE)
- Congolese Franc
- CDF
- 976
- 2
-
-
- CONGO (THE)
- CFA Franc BEAC
- XAF
- 950
- 0
-
-
- COOK ISLANDS (THE)
- New Zealand Dollar
- NZD
- 554
- 2
-
-
- COSTA RICA
- Costa Rican Colon
- CRC
- 188
- 2
-
-
- CÔTE D'IVOIRE
- CFA Franc BCEAO
- XOF
- 952
- 0
-
-
- CROATIA
- Kuna
- HRK
- 191
- 2
-
-
- CUBA
- Cuban Peso
- CUP
- 192
- 2
-
-
- CUBA
- Peso Convertible
- CUC
- 931
- 2
-
-
- CURAÇAO
- Netherlands Antillean Guilder
- ANG
- 532
- 2
-
-
- CYPRUS
- Euro
- EUR
- 978
- 2
-
-
- CZECHIA
- Czech Koruna
- CZK
- 203
- 2
-
-
- DENMARK
- Danish Krone
- DKK
- 208
- 2
-
-
- DJIBOUTI
- Djibouti Franc
- DJF
- 262
- 0
-
-
- DOMINICA
- East Caribbean Dollar
- XCD
- 951
- 2
-
-
- DOMINICAN REPUBLIC (THE)
- Dominican Peso
- DOP
- 214
- 2
-
-
- ECUADOR
- US Dollar
- USD
- 840
- 2
-
-
- EGYPT
- Egyptian Pound
- EGP
- 818
- 2
-
-
- EL SALVADOR
- El Salvador Colon
- SVC
- 222
- 2
-
-
- EL SALVADOR
- US Dollar
- USD
- 840
- 2
-
-
- EQUATORIAL GUINEA
- CFA Franc BEAC
- XAF
- 950
- 0
-
-
- ERITREA
- Nakfa
- ERN
- 232
- 2
-
-
- ESTONIA
- Euro
- EUR
- 978
- 2
-
-
- ETHIOPIA
- Ethiopian Birr
- ETB
- 230
- 2
-
-
- EUROPEAN UNION
- Euro
- EUR
- 978
- 2
-
-
- FALKLAND ISLANDS (THE) [MALVINAS]
- Falkland Islands Pound
- FKP
- 238
- 2
-
-
- FAROE ISLANDS (THE)
- Danish Krone
- DKK
- 208
- 2
-
-
- FIJI
- Fiji Dollar
- FJD
- 242
- 2
-
-
- FINLAND
- Euro
- EUR
- 978
- 2
-
-
- FRANCE
- Euro
- EUR
- 978
- 2
-
-
- FRENCH GUIANA
- Euro
- EUR
- 978
- 2
-
-
- FRENCH POLYNESIA
- CFP Franc
- XPF
- 953
- 0
-
-
- FRENCH SOUTHERN TERRITORIES (THE)
- Euro
- EUR
- 978
- 2
-
-
- GABON
- CFA Franc BEAC
- XAF
- 950
- 0
-
-
- GAMBIA (THE)
- Dalasi
- GMD
- 270
- 2
-
-
- GEORGIA
- Lari
- GEL
- 981
- 2
-
-
- GERMANY
- Euro
- EUR
- 978
- 2
-
-
- GHANA
- Ghana Cedi
- GHS
- 936
- 2
-
-
- GIBRALTAR
- Gibraltar Pound
- GIP
- 292
- 2
-
-
- GREECE
- Euro
- EUR
- 978
- 2
-
-
- GREENLAND
- Danish Krone
- DKK
- 208
- 2
-
-
- GRENADA
- East Caribbean Dollar
- XCD
- 951
- 2
-
-
- GUADELOUPE
- Euro
- EUR
- 978
- 2
-
-
- GUAM
- US Dollar
- USD
- 840
- 2
-
-
- GUATEMALA
- Quetzal
- GTQ
- 320
- 2
-
-
- GUERNSEY
- Pound Sterling
- GBP
- 826
- 2
-
-
- GUINEA
- Guinean Franc
- GNF
- 324
- 0
-
-
- GUINEA-BISSAU
- CFA Franc BCEAO
- XOF
- 952
- 0
-
-
- GUYANA
- Guyana Dollar
- GYD
- 328
- 2
-
-
- HAITI
- Gourde
- HTG
- 332
- 2
-
-
- HAITI
- US Dollar
- USD
- 840
- 2
-
-
- HEARD ISLAND AND McDONALD ISLANDS
- Australian Dollar
- AUD
- 036
- 2
-
-
- HOLY SEE (THE)
- Euro
- EUR
- 978
- 2
-
-
- HONDURAS
- Lempira
- HNL
- 340
- 2
-
-
- HONG KONG
- Hong Kong Dollar
- HKD
- 344
- 2
-
-
- HUNGARY
- Forint
- HUF
- 348
- 2
-
-
- ICELAND
- Iceland Krona
- ISK
- 352
- 0
-
-
- INDIA
- Indian Rupee
- INR
- 356
- 2
-
-
- INDONESIA
- Rupiah
- IDR
- 360
- 2
-
-
- INTERNATIONAL MONETARY FUND (IMF)
- SDR (Special Drawing Right)
- XDR
- 960
- N.A.
-
-
- IRAN (ISLAMIC REPUBLIC OF)
- Iranian Rial
- IRR
- 364
- 2
-
-
- IRAQ
- Iraqi Dinar
- IQD
- 368
- 3
-
-
- IRELAND
- Euro
- EUR
- 978
- 2
-
-
- ISLE OF MAN
- Pound Sterling
- GBP
- 826
- 2
-
-
- ISRAEL
- New Israeli Sheqel
- ILS
- 376
- 2
-
-
- ITALY
- Euro
- EUR
- 978
- 2
-
-
- JAMAICA
- Jamaican Dollar
- JMD
- 388
- 2
-
-
- JAPAN
- Yen
- JPY
- 392
- 0
-
-
- JERSEY
- Pound Sterling
- GBP
- 826
- 2
-
-
- JORDAN
- Jordanian Dinar
- JOD
- 400
- 3
-
-
- KAZAKHSTAN
- Tenge
- KZT
- 398
- 2
-
-
- KENYA
- Kenyan Shilling
- KES
- 404
- 2
-
-
- KIRIBATI
- Australian Dollar
- AUD
- 036
- 2
-
-
- KOREA (THE DEMOCRATIC PEOPLE’S REPUBLIC OF)
- North Korean Won
- KPW
- 408
- 2
-
-
- KOREA (THE REPUBLIC OF)
- Won
- KRW
- 410
- 0
-
-
- KUWAIT
- Kuwaiti Dinar
- KWD
- 414
- 3
-
-
- KYRGYZSTAN
- Som
- KGS
- 417
- 2
-
-
- LAO PEOPLE’S DEMOCRATIC REPUBLIC (THE)
- Lao Kip
- LAK
- 418
- 2
-
-
- LATVIA
- Euro
- EUR
- 978
- 2
-
-
- LEBANON
- Lebanese Pound
- LBP
- 422
- 2
-
-
- LESOTHO
- Loti
- LSL
- 426
- 2
-
-
- LESOTHO
- Rand
- ZAR
- 710
- 2
-
-
- LIBERIA
- Liberian Dollar
- LRD
- 430
- 2
-
-
- LIBYA
- Libyan Dinar
- LYD
- 434
- 3
-
-
- LIECHTENSTEIN
- Swiss Franc
- CHF
- 756
- 2
-
-
- LITHUANIA
- Euro
- EUR
- 978
- 2
-
-
- LUXEMBOURG
- Euro
- EUR
- 978
- 2
-
-
- MACAO
- Pataca
- MOP
- 446
- 2
-
-
- MACEDONIA (THE FORMER YUGOSLAV REPUBLIC OF)
- Denar
- MKD
- 807
- 2
-
-
- MADAGASCAR
- Malagasy Ariary
- MGA
- 969
- 2
-
-
- MALAWI
- Malawi Kwacha
- MWK
- 454
- 2
-
-
- MALAYSIA
- Malaysian Ringgit
- MYR
- 458
- 2
-
-
- MALDIVES
- Rufiyaa
- MVR
- 462
- 2
-
-
- MALI
- CFA Franc BCEAO
- XOF
- 952
- 0
-
-
- MALTA
- Euro
- EUR
- 978
- 2
-
-
- MARSHALL ISLANDS (THE)
- US Dollar
- USD
- 840
- 2
-
-
- MARTINIQUE
- Euro
- EUR
- 978
- 2
-
-
- MAURITANIA
- Ouguiya
- MRU
- 929
- 2
-
-
- MAURITIUS
- Mauritius Rupee
- MUR
- 480
- 2
-
-
- MAYOTTE
- Euro
- EUR
- 978
- 2
-
-
- MEMBER COUNTRIES OF THE AFRICAN DEVELOPMENT BANK GROUP
- ADB Unit of Account
- XUA
- 965
- N.A.
-
-
- MEXICO
- Mexican Peso
- MXN
- 484
- 2
-
-
- MEXICO
- Mexican Unidad de Inversion (UDI)
- MXV
- 979
- 2
-
-
- MICRONESIA (FEDERATED STATES OF)
- US Dollar
- USD
- 840
- 2
-
-
- MOLDOVA (THE REPUBLIC OF)
- Moldovan Leu
- MDL
- 498
- 2
-
-
- MONACO
- Euro
- EUR
- 978
- 2
-
-
- MONGOLIA
- Tugrik
- MNT
- 496
- 2
-
-
- MONTENEGRO
- Euro
- EUR
- 978
- 2
-
-
- MONTSERRAT
- East Caribbean Dollar
- XCD
- 951
- 2
-
-
- MOROCCO
- Moroccan Dirham
- MAD
- 504
- 2
-
-
- MOZAMBIQUE
- Mozambique Metical
- MZN
- 943
- 2
-
-
- MYANMAR
- Kyat
- MMK
- 104
- 2
-
-
- NAMIBIA
- Namibia Dollar
- NAD
- 516
- 2
-
-
- NAMIBIA
- Rand
- ZAR
- 710
- 2
-
-
- NAURU
- Australian Dollar
- AUD
- 036
- 2
-
-
- NEPAL
- Nepalese Rupee
- NPR
- 524
- 2
-
-
- NETHERLANDS (THE)
- Euro
- EUR
- 978
- 2
-
-
- NEW CALEDONIA
- CFP Franc
- XPF
- 953
- 0
-
-
- NEW ZEALAND
- New Zealand Dollar
- NZD
- 554
- 2
-
-
- NICARAGUA
- Cordoba Oro
- NIO
- 558
- 2
-
-
- NIGER (THE)
- CFA Franc BCEAO
- XOF
- 952
- 0
-
-
- NIGERIA
- Naira
- NGN
- 566
- 2
-
-
- NIUE
- New Zealand Dollar
- NZD
- 554
- 2
-
-
- NORFOLK ISLAND
- Australian Dollar
- AUD
- 036
- 2
-
-
- NORTHERN MARIANA ISLANDS (THE)
- US Dollar
- USD
- 840
- 2
-
-
- NORWAY
- Norwegian Krone
- NOK
- 578
- 2
-
-
- OMAN
- Rial Omani
- OMR
- 512
- 3
-
-
- PAKISTAN
- Pakistan Rupee
- PKR
- 586
- 2
-
-
- PALAU
- US Dollar
- USD
- 840
- 2
-
-
- PALESTINE, STATE OF
- No universal currency
-
-
- PANAMA
- Balboa
- PAB
- 590
- 2
-
-
- PANAMA
- US Dollar
- USD
- 840
- 2
-
-
- PAPUA NEW GUINEA
- Kina
- PGK
- 598
- 2
-
-
- PARAGUAY
- Guarani
- PYG
- 600
- 0
-
-
- PERU
- Sol
- PEN
- 604
- 2
-
-
- PHILIPPINES (THE)
- Philippine Peso
- PHP
- 608
- 2
-
-
- PITCAIRN
- New Zealand Dollar
- NZD
- 554
- 2
-
-
- POLAND
- Zloty
- PLN
- 985
- 2
-
-
- PORTUGAL
- Euro
- EUR
- 978
- 2
-
-
- PUERTO RICO
- US Dollar
- USD
- 840
- 2
-
-
- QATAR
- Qatari Rial
- QAR
- 634
- 2
-
-
- RÉUNION
- Euro
- EUR
- 978
- 2
-
-
- ROMANIA
- Romanian Leu
- RON
- 946
- 2
-
-
- RUSSIAN FEDERATION (THE)
- Russian Ruble
- RUB
- 643
- 2
-
-
- RWANDA
- Rwanda Franc
- RWF
- 646
- 0
-
-
- SAINT BARTHÉLEMY
- Euro
- EUR
- 978
- 2
-
-
- SAINT HELENA, ASCENSION AND TRISTAN DA CUNHA
- Saint Helena Pound
- SHP
- 654
- 2
-
-
- SAINT KITTS AND NEVIS
- East Caribbean Dollar
- XCD
- 951
- 2
-
-
- SAINT LUCIA
- East Caribbean Dollar
- XCD
- 951
- 2
-
-
- SAINT MARTIN (FRENCH PART)
- Euro
- EUR
- 978
- 2
-
-
- SAINT PIERRE AND MIQUELON
- Euro
- EUR
- 978
- 2
-
-
- SAINT VINCENT AND THE GRENADINES
- East Caribbean Dollar
- XCD
- 951
- 2
-
-
- SAMOA
- Tala
- WST
- 882
- 2
-
-
- SAN MARINO
- Euro
- EUR
- 978
- 2
-
-
- SAO TOME AND PRINCIPE
- Dobra
- STN
- 930
- 2
-
-
- SAUDI ARABIA
- Saudi Riyal
- SAR
- 682
- 2
-
-
- SENEGAL
- CFA Franc BCEAO
- XOF
- 952
- 0
-
-
- SERBIA
- Serbian Dinar
- RSD
- 941
- 2
-
-
- SEYCHELLES
- Seychelles Rupee
- SCR
- 690
- 2
-
-
- SIERRA LEONE
- Leone
- SLL
- 694
- 2
-
-
- SINGAPORE
- Singapore Dollar
- SGD
- 702
- 2
-
-
- SINT MAARTEN (DUTCH PART)
- Netherlands Antillean Guilder
- ANG
- 532
- 2
-
-
- SISTEMA UNITARIO DE COMPENSACION REGIONAL DE PAGOS "SUCRE"
- Sucre
- XSU
- 994
- N.A.
-
-
- SLOVAKIA
- Euro
- EUR
- 978
- 2
-
-
- SLOVENIA
- Euro
- EUR
- 978
- 2
-
-
- SOLOMON ISLANDS
- Solomon Islands Dollar
- SBD
- 090
- 2
-
-
- SOMALIA
- Somali Shilling
- SOS
- 706
- 2
-
-
- SOUTH AFRICA
- Rand
- ZAR
- 710
- 2
-
-
- SOUTH GEORGIA AND THE SOUTH SANDWICH ISLANDS
- No universal currency
-
-
- SOUTH SUDAN
- South Sudanese Pound
- SSP
- 728
- 2
-
-
- SPAIN
- Euro
- EUR
- 978
- 2
-
-
- SRI LANKA
- Sri Lanka Rupee
- LKR
- 144
- 2
-
-
- SUDAN (THE)
- Sudanese Pound
- SDG
- 938
- 2
-
-
- SURINAME
- Surinam Dollar
- SRD
- 968
- 2
-
-
- SVALBARD AND JAN MAYEN
- Norwegian Krone
- NOK
- 578
- 2
-
-
- ESWATINI
- Lilangeni
- SZL
- 748
- 2
-
-
- SWEDEN
- Swedish Krona
- SEK
- 752
- 2
-
-
- SWITZERLAND
- Swiss Franc
- CHF
- 756
- 2
-
-
- SWITZERLAND
- WIR Euro
- CHE
- 947
- 2
-
-
- SWITZERLAND
- WIR Franc
- CHW
- 948
- 2
-
-
- SYRIAN ARAB REPUBLIC
- Syrian Pound
- SYP
- 760
- 2
-
-
- TAIWAN (PROVINCE OF CHINA)
- New Taiwan Dollar
- TWD
- 901
- 2
-
-
- TAJIKISTAN
- Somoni
- TJS
- 972
- 2
-
-
- TANZANIA, UNITED REPUBLIC OF
- Tanzanian Shilling
- TZS
- 834
- 2
-
-
- THAILAND
- Baht
- THB
- 764
- 2
-
-
- TIMOR-LESTE
- US Dollar
- USD
- 840
- 2
-
-
- TOGO
- CFA Franc BCEAO
- XOF
- 952
- 0
-
-
- TOKELAU
- New Zealand Dollar
- NZD
- 554
- 2
-
-
- TONGA
- Pa’anga
- TOP
- 776
- 2
-
-
- TRINIDAD AND TOBAGO
- Trinidad and Tobago Dollar
- TTD
- 780
- 2
-
-
- TUNISIA
- Tunisian Dinar
- TND
- 788
- 3
-
-
- TURKEY
- Turkish Lira
- TRY
- 949
- 2
-
-
- TURKMENISTAN
- Turkmenistan New Manat
- TMT
- 934
- 2
-
-
- TURKS AND CAICOS ISLANDS (THE)
- US Dollar
- USD
- 840
- 2
-
-
- TUVALU
- Australian Dollar
- AUD
- 036
- 2
-
-
- UGANDA
- Uganda Shilling
- UGX
- 800
- 0
-
-
- UKRAINE
- Hryvnia
- UAH
- 980
- 2
-
-
- UNITED ARAB EMIRATES (THE)
- UAE Dirham
- AED
- 784
- 2
-
-
- UNITED KINGDOM OF GREAT BRITAIN AND NORTHERN IRELAND (THE)
- Pound Sterling
- GBP
- 826
- 2
-
-
- UNITED STATES MINOR OUTLYING ISLANDS (THE)
- US Dollar
- USD
- 840
- 2
-
-
- UNITED STATES OF AMERICA (THE)
- US Dollar
- USD
- 840
- 2
-
-
- UNITED STATES OF AMERICA (THE)
- US Dollar (Next day)
- USN
- 997
- 2
-
-
- URUGUAY
- Peso Uruguayo
- UYU
- 858
- 2
-
-
- URUGUAY
- Uruguay Peso en Unidades Indexadas (UI)
- UYI
- 940
- 0
-
-
- URUGUAY
- Unidad Previsional
- UYW
- 927
- 4
-
-
- UZBEKISTAN
- Uzbekistan Sum
- UZS
- 860
- 2
-
-
- VANUATU
- Vatu
- VUV
- 548
- 0
-
-
- VENEZUELA (BOLIVARIAN REPUBLIC OF)
- Bolívar Soberano
- VES
- 928
- 2
-
-
- VIET NAM
- Dong
- VND
- 704
- 0
-
-
- VIRGIN ISLANDS (BRITISH)
- US Dollar
- USD
- 840
- 2
-
-
- VIRGIN ISLANDS (U.S.)
- US Dollar
- USD
- 840
- 2
-
-
- WALLIS AND FUTUNA
- CFP Franc
- XPF
- 953
- 0
-
-
- WESTERN SAHARA
- Moroccan Dirham
- MAD
- 504
- 2
-
-
- YEMEN
- Yemeni Rial
- YER
- 886
- 2
-
-
- ZAMBIA
- Zambian Kwacha
- ZMW
- 967
- 2
-
-
- ZIMBABWE
- Zimbabwe Dollar
- ZWL
- 932
- 2
-
-
- ZZ01_Bond Markets Unit European_EURCO
- Bond Markets Unit European Composite Unit (EURCO)
- XBA
- 955
- N.A.
-
-
- ZZ02_Bond Markets Unit European_EMU-6
- Bond Markets Unit European Monetary Unit (E.M.U.-6)
- XBB
- 956
- N.A.
-
-
- ZZ03_Bond Markets Unit European_EUA-9
- Bond Markets Unit European Unit of Account 9 (E.U.A.-9)
- XBC
- 957
- N.A.
-
-
- ZZ04_Bond Markets Unit European_EUA-17
- Bond Markets Unit European Unit of Account 17 (E.U.A.-17)
- XBD
- 958
- N.A.
-
-
- ZZ06_Testing_Code
- Codes specifically reserved for testing purposes
- XTS
- 963
- N.A.
-
-
- ZZ07_No_Currency
- The codes assigned for transactions where no currency is involved
- XXX
- 999
- N.A.
-
-
- ZZ08_Gold
- Gold
- XAU
- 959
- N.A.
-
-
- ZZ09_Palladium
- Palladium
- XPD
- 964
- N.A.
-
-
- ZZ10_Platinum
- Platinum
- XPT
- 962
- N.A.
-
-
- ZZ11_Silver
- Silver
- XAG
- 961
- N.A.
-
-
+
+
+
+ AFGHANISTAN
+ Afghani
+ AFN
+ 971
+ 2
+
+
+ ÅLAND ISLANDS
+ Euro
+ EUR
+ 978
+ 2
+
+
+ ALBANIA
+ Lek
+ ALL
+ 008
+ 2
+
+
+ ALGERIA
+ Algerian Dinar
+ DZD
+ 012
+ 2
+
+
+ AMERICAN SAMOA
+ US Dollar
+ USD
+ 840
+ 2
+
+
+ ANDORRA
+ Euro
+ EUR
+ 978
+ 2
+
+
+ ANGOLA
+ Kwanza
+ AOA
+ 973
+ 2
+
+
+ ANGUILLA
+ East Caribbean Dollar
+ XCD
+ 951
+ 2
+
+
+ ANTARCTICA
+ No universal currency
+
+
+ ANTIGUA AND BARBUDA
+ East Caribbean Dollar
+ XCD
+ 951
+ 2
+
+
+ ARGENTINA
+ Argentine Peso
+ ARS
+ 032
+ 2
+
+
+ ARMENIA
+ Armenian Dram
+ AMD
+ 051
+ 2
+
+
+ ARUBA
+ Aruban Florin
+ AWG
+ 533
+ 2
+
+
+ AUSTRALIA
+ Australian Dollar
+ AUD
+ 036
+ 2
+
+
+ AUSTRIA
+ Euro
+ EUR
+ 978
+ 2
+
+
+ AZERBAIJAN
+ Azerbaijanian Manat
+ AZN
+ 944
+ 2
+
+
+ BAHAMAS
+ Bahamian Dollar
+ BSD
+ 044
+ 2
+
+
+ BAHRAIN
+ Bahraini Dinar
+ BHD
+ 048
+ 3
+
+
+ BANGLADESH
+ Taka
+ BDT
+ 050
+ 2
+
+
+ BARBADOS
+ Barbados Dollar
+ BBD
+ 052
+ 2
+
+
+ BELARUS
+ Belarussian Ruble
+ BYR
+ 974
+ 0
+
+
+ BELGIUM
+ Euro
+ EUR
+ 978
+ 2
+
+
+ BELIZE
+ Belize Dollar
+ BZD
+ 084
+ 2
+
+
+ BENIN
+ CFA Franc BCEAO
+ XOF
+ 952
+ 0
+
+
+ BERMUDA
+ Bermudian Dollar
+ BMD
+ 060
+ 2
+
+
+ BHUTAN
+ Ngultrum
+ BTN
+ 064
+ 2
+
+
+ BHUTAN
+ Indian Rupee
+ INR
+ 356
+ 2
+
+
+ BOLIVIA, PLURINATIONAL STATE OF
+ Boliviano
+ BOB
+ 068
+ 2
+
+
+ BOLIVIA, PLURINATIONAL STATE OF
+ Mvdol
+ BOV
+ 984
+ 2
+
+
+ BONAIRE, SINT EUSTATIUS AND SABA
+ US Dollar
+ USD
+ 840
+ 2
+
+
+ BOSNIA AND HERZEGOVINA
+ Convertible Mark
+ BAM
+ 977
+ 2
+
+
+ BOTSWANA
+ Pula
+ BWP
+ 072
+ 2
+
+
+ BOUVET ISLAND
+ Norwegian Krone
+ NOK
+ 578
+ 2
+
+
+ BRAZIL
+ Brazilian Real
+ BRL
+ 986
+ 2
+
+
+ BRITISH INDIAN OCEAN TERRITORY
+ US Dollar
+ USD
+ 840
+ 2
+
+
+ BRUNEI DARUSSALAM
+ Brunei Dollar
+ BND
+ 096
+ 2
+
+
+ BULGARIA
+ Bulgarian Lev
+ BGN
+ 975
+ 2
+
+
+ BURKINA FASO
+ CFA Franc BCEAO
+ XOF
+ 952
+ 0
+
+
+ BURUNDI
+ Burundi Franc
+ BIF
+ 108
+ 0
+
+
+ CAMBODIA
+ Riel
+ KHR
+ 116
+ 2
+
+
+ CAMEROON
+ CFA Franc BEAC
+ XAF
+ 950
+ 0
+
+
+ CANADA
+ Canadian Dollar
+ CAD
+ 124
+ 2
+
+
+ CABO VERDE
+ Cabo Verde Escudo
+ CVE
+ 132
+ 2
+
+
+ CAYMAN ISLANDS
+ Cayman Islands Dollar
+ KYD
+ 136
+ 2
+
+
+ CENTRAL AFRICAN REPUBLIC
+ CFA Franc BEAC
+ XAF
+ 950
+ 0
+
+
+ CHAD
+ CFA Franc BEAC
+ XAF
+ 950
+ 0
+
+
+ CHILE
+ Unidad de Fomento
+ CLF
+ 990
+ 4
+
+
+ CHILE
+ Chilean Peso
+ CLP
+ 152
+ 0
+
+
+ CHINA
+ Yuan Renminbi
+ CNY
+ 156
+ 2
+
+
+ CHRISTMAS ISLAND
+ Australian Dollar
+ AUD
+ 036
+ 2
+
+
+ COCOS (KEELING) ISLANDS
+ Australian Dollar
+ AUD
+ 036
+ 2
+
+
+ COLOMBIA
+ Colombian Peso
+ COP
+ 170
+ 2
+
+
+ COLOMBIA
+ Unidad de Valor Real
+ COU
+ 970
+ 2
+
+
+ COMOROS
+ Comoro Franc
+ KMF
+ 174
+ 0
+
+
+ CONGO
+ CFA Franc BEAC
+ XAF
+ 950
+ 0
+
+
+ CONGO, DEMOCRATIC REPUBLIC OF THE
+ Congolese Franc
+ CDF
+ 976
+ 2
+
+
+ COOK ISLANDS
+ New Zealand Dollar
+ NZD
+ 554
+ 2
+
+
+ COSTA RICA
+ Costa Rican Colon
+ CRC
+ 188
+ 2
+
+
+ CÔTE D'IVOIRE
+ CFA Franc BCEAO
+ XOF
+ 952
+ 0
+
+
+ CROATIA
+ Croatian Kuna
+ HRK
+ 191
+ 2
+
+
+ CUBA
+ Peso Convertible
+ CUC
+ 931
+ 2
+
+
+ CUBA
+ Cuban Peso
+ CUP
+ 192
+ 2
+
+
+ CURAÇAO
+ Netherlands Antillean Guilder
+ ANG
+ 532
+ 2
+
+
+ CYPRUS
+ Euro
+ EUR
+ 978
+ 2
+
+
+ CZECH REPUBLIC
+ Czech Koruna
+ CZK
+ 203
+ 2
+
+
+ DENMARK
+ Danish Krone
+ DKK
+ 208
+ 2
+
+
+ DJIBOUTI
+ Djibouti Franc
+ DJF
+ 262
+ 0
+
+
+ DOMINICA
+ East Caribbean Dollar
+ XCD
+ 951
+ 2
+
+
+ DOMINICAN REPUBLIC
+ Dominican Peso
+ DOP
+ 214
+ 2
+
+
+ ECUADOR
+ US Dollar
+ USD
+ 840
+ 2
+
+
+ EGYPT
+ Egyptian Pound
+ EGP
+ 818
+ 2
+
+
+ EL SALVADOR
+ El Salvador Colon
+ SVC
+ 222
+ 2
+
+
+ EL SALVADOR
+ US Dollar
+ USD
+ 840
+ 2
+
+
+ EQUATORIAL GUINEA
+ CFA Franc BEAC
+ XAF
+ 950
+ 0
+
+
+ ERITREA
+ Nakfa
+ ERN
+ 232
+ 2
+
+
+ ESTONIA
+ Euro
+ EUR
+ 978
+ 2
+
+
+ ETHIOPIA
+ Ethiopian Birr
+ ETB
+ 230
+ 2
+
+
+ EUROPEAN UNION
+ Euro
+ EUR
+ 978
+ 2
+
+
+ FALKLAND ISLANDS (MALVINAS)
+ Falkland Islands Pound
+ FKP
+ 238
+ 2
+
+
+ FAROE ISLANDS
+ Danish Krone
+ DKK
+ 208
+ 2
+
+
+ FIJI
+ Fiji Dollar
+ FJD
+ 242
+ 2
+
+
+ FINLAND
+ Euro
+ EUR
+ 978
+ 2
+
+
+ FRANCE
+ Euro
+ EUR
+ 978
+ 2
+
+
+ FRENCH GUIANA
+ Euro
+ EUR
+ 978
+ 2
+
+
+ FRENCH POLYNESIA
+ CFP Franc
+ XPF
+ 953
+ 0
+
+
+ FRENCH SOUTHERN TERRITORIES
+ Euro
+ EUR
+ 978
+ 2
+
+
+ GABON
+ CFA Franc BEAC
+ XAF
+ 950
+ 0
+
+
+ GAMBIA
+ Dalasi
+ GMD
+ 270
+ 2
+
+
+ GEORGIA
+ Lari
+ GEL
+ 981
+ 2
+
+
+ GERMANY
+ Euro
+ EUR
+ 978
+ 2
+
+
+ GHANA
+ Ghana Cedi
+ GHS
+ 936
+ 2
+
+
+ GIBRALTAR
+ Gibraltar Pound
+ GIP
+ 292
+ 2
+
+
+ GREECE
+ Euro
+ EUR
+ 978
+ 2
+
+
+ GREENLAND
+ Danish Krone
+ DKK
+ 208
+ 2
+
+
+ GRENADA
+ East Caribbean Dollar
+ XCD
+ 951
+ 2
+
+
+ GUADELOUPE
+ Euro
+ EUR
+ 978
+ 2
+
+
+ GUAM
+ US Dollar
+ USD
+ 840
+ 2
+
+
+ GUATEMALA
+ Quetzal
+ GTQ
+ 320
+ 2
+
+
+ GUERNSEY
+ Pound Sterling
+ GBP
+ 826
+ 2
+
+
+ GUINEA
+ Guinea Franc
+ GNF
+ 324
+ 0
+
+
+ GUINEA-BISSAU
+ CFA Franc BCEAO
+ XOF
+ 952
+ 0
+
+
+ GUYANA
+ Guyana Dollar
+ GYD
+ 328
+ 2
+
+
+ HAITI
+ Gourde
+ HTG
+ 332
+ 2
+
+
+ HAITI
+ US Dollar
+ USD
+ 840
+ 2
+
+
+ HEARD ISLAND AND McDONALD ISLANDS
+ Australian Dollar
+ AUD
+ 036
+ 2
+
+
+ HOLY SEE (VATICAN CITY STATE)
+ Euro
+ EUR
+ 978
+ 2
+
+
+ HONDURAS
+ Lempira
+ HNL
+ 340
+ 2
+
+
+ HONG KONG
+ Hong Kong Dollar
+ HKD
+ 344
+ 2
+
+
+ HUNGARY
+ Forint
+ HUF
+ 348
+ 2
+
+
+ ICELAND
+ Iceland Krona
+ ISK
+ 352
+ 0
+
+
+ INDIA
+ Indian Rupee
+ INR
+ 356
+ 2
+
+
+ INDONESIA
+ Rupiah
+ IDR
+ 360
+ 2
+
+
+ INTERNATIONAL MONETARY FUND (IMF)
+ SDR (Special Drawing Right)
+ XDR
+ 960
+ N.A.
+
+
+ IRAN, ISLAMIC REPUBLIC OF
+ Iranian Rial
+ IRR
+ 364
+ 2
+
+
+ IRAQ
+ Iraqi Dinar
+ IQD
+ 368
+ 3
+
+
+ IRELAND
+ Euro
+ EUR
+ 978
+ 2
+
+
+ ISLE OF MAN
+ Pound Sterling
+ GBP
+ 826
+ 2
+
+
+ ISRAEL
+ New Israeli Sheqel
+ ILS
+ 376
+ 2
+
+
+ ITALY
+ Euro
+ EUR
+ 978
+ 2
+
+
+ JAMAICA
+ Jamaican Dollar
+ JMD
+ 388
+ 2
+
+
+ JAPAN
+ Yen
+ JPY
+ 392
+ 0
+
+
+ JERSEY
+ Pound Sterling
+ GBP
+ 826
+ 2
+
+
+ JORDAN
+ Jordanian Dinar
+ JOD
+ 400
+ 3
+
+
+ KAZAKHSTAN
+ Tenge
+ KZT
+ 398
+ 2
+
+
+ KENYA
+ Kenyan Shilling
+ KES
+ 404
+ 2
+
+
+ KIRIBATI
+ Australian Dollar
+ AUD
+ 036
+ 2
+
+
+ KOREA, DEMOCRATIC PEOPLE’S REPUBLIC OF
+ North Korean Won
+ KPW
+ 408
+ 2
+
+
+ KOREA, REPUBLIC OF
+ Won
+ KRW
+ 410
+ 0
+
+
+ KUWAIT
+ Kuwaiti Dinar
+ KWD
+ 414
+ 3
+
+
+ KYRGYZSTAN
+ Som
+ KGS
+ 417
+ 2
+
+
+ LAO PEOPLE’S DEMOCRATIC REPUBLIC
+ Kip
+ LAK
+ 418
+ 2
+
+
+ LATVIA
+ Euro
+ EUR
+ 978
+ 2
+
+
+ LEBANON
+ Lebanese Pound
+ LBP
+ 422
+ 2
+
+
+ LESOTHO
+ Loti
+ LSL
+ 426
+ 2
+
+
+ LESOTHO
+ Rand
+ ZAR
+ 710
+ 2
+
+
+ LIBERIA
+ Liberian Dollar
+ LRD
+ 430
+ 2
+
+
+ LIBYA
+ Libyan Dinar
+ LYD
+ 434
+ 3
+
+
+ LIECHTENSTEIN
+ Swiss Franc
+ CHF
+ 756
+ 2
+
+
+ LITHUANIA
+ Lithuanian Litas
+ LTL
+ 440
+ 2
+
+
+ LUXEMBOURG
+ Euro
+ EUR
+ 978
+ 2
+
+
+ MACAO
+ Pataca
+ MOP
+ 446
+ 2
+
+
+ MACEDONIA, THE FORMER
+ YUGOSLAV REPUBLIC OF
+ Denar
+ MKD
+ 807
+ 2
+
+
+ MADAGASCAR
+ Malagasy Ariary
+ MGA
+ 969
+ 2
+
+
+ MALAWI
+ Kwacha
+ MWK
+ 454
+ 2
+
+
+ MALAYSIA
+ Malaysian Ringgit
+ MYR
+ 458
+ 2
+
+
+ MALDIVES
+ Rufiyaa
+ MVR
+ 462
+ 2
+
+
+ MALI
+ CFA Franc BCEAO
+ XOF
+ 952
+ 0
+
+
+ MALTA
+ Euro
+ EUR
+ 978
+ 2
+
+
+ MARSHALL ISLANDS
+ US Dollar
+ USD
+ 840
+ 2
+
+
+ MARTINIQUE
+ Euro
+ EUR
+ 978
+ 2
+
+
+ MAURITANIA
+ Ouguiya
+ MRO
+ 478
+ 2
+
+
+ MAURITIUS
+ Mauritius Rupee
+ MUR
+ 480
+ 2
+
+
+ MAYOTTE
+ Euro
+ EUR
+ 978
+ 2
+
+
+ MEMBER COUNTRIES OF THE AFRICAN DEVELOPMENT BANK GROUP
+ ADB Unit of Account
+ XUA
+ 965
+ N.A.
+
+
+ MEXICO
+ Mexican Peso
+ MXN
+ 484
+ 2
+
+
+ MEXICO
+ Mexican Unidad de Inversion (UDI)
+ MXV
+ 979
+ 2
+
+
+ MICRONESIA, FEDERATED STATES OF
+ US Dollar
+ USD
+ 840
+ 2
+
+
+ MOLDOVA, REPUBLIC OF
+ Moldovan Leu
+ MDL
+ 498
+ 2
+
+
+ MONACO
+ Euro
+ EUR
+ 978
+ 2
+
+
+ MONGOLIA
+ Tugrik
+ MNT
+ 496
+ 2
+
+
+ MONTENEGRO
+ Euro
+ EUR
+ 978
+ 2
+
+
+ MONTSERRAT
+ East Caribbean Dollar
+ XCD
+ 951
+ 2
+
+
+ MOROCCO
+ Moroccan Dirham
+ MAD
+ 504
+ 2
+
+
+ MOZAMBIQUE
+ Mozambique Metical
+ MZN
+ 943
+ 2
+
+
+ MYANMAR
+ Kyat
+ MMK
+ 104
+ 2
+
+
+ NAMIBIA
+ Namibia Dollar
+ NAD
+ 516
+ 2
+
+
+ NAMIBIA
+ Rand
+ ZAR
+ 710
+ 2
+
+
+ NAURU
+ Australian Dollar
+ AUD
+ 036
+ 2
+
+
+ NEPAL
+ Nepalese Rupee
+ NPR
+ 524
+ 2
+
+
+ NETHERLANDS
+ Euro
+ EUR
+ 978
+ 2
+
+
+ NEW CALEDONIA
+ CFP Franc
+ XPF
+ 953
+ 0
+
+
+ NEW ZEALAND
+ New Zealand Dollar
+ NZD
+ 554
+ 2
+
+
+ NICARAGUA
+ Cordoba Oro
+ NIO
+ 558
+ 2
+
+
+ NIGER
+ CFA Franc BCEAO
+ XOF
+ 952
+ 0
+
+
+ NIGERIA
+ Naira
+ NGN
+ 566
+ 2
+
+
+ NIUE
+ New Zealand Dollar
+ NZD
+ 554
+ 2
+
+
+ NORFOLK ISLAND
+ Australian Dollar
+ AUD
+ 036
+ 2
+
+
+ NORTHERN MARIANA ISLANDS
+ US Dollar
+ USD
+ 840
+ 2
+
+
+ NORWAY
+ Norwegian Krone
+ NOK
+ 578
+ 2
+
+
+ OMAN
+ Rial Omani
+ OMR
+ 512
+ 3
+
+
+ PAKISTAN
+ Pakistan Rupee
+ PKR
+ 586
+ 2
+
+
+ PALAU
+ US Dollar
+ USD
+ 840
+ 2
+
+
+ PALESTINE, STATE OF
+ No universal currency
+
+
+ PANAMA
+ Balboa
+ PAB
+ 590
+ 2
+
+
+ PANAMA
+ US Dollar
+ USD
+ 840
+ 2
+
+
+ PAPUA NEW GUINEA
+ Kina
+ PGK
+ 598
+ 2
+
+
+ PARAGUAY
+ Guarani
+ PYG
+ 600
+ 0
+
+
+ PERU
+ Nuevo Sol
+ PEN
+ 604
+ 2
+
+
+ PHILIPPINES
+ Philippine Peso
+ PHP
+ 608
+ 2
+
+
+ PITCAIRN
+ New Zealand Dollar
+ NZD
+ 554
+ 2
+
+
+ POLAND
+ Zloty
+ PLN
+ 985
+ 2
+
+
+ PORTUGAL
+ Euro
+ EUR
+ 978
+ 2
+
+
+ PUERTO RICO
+ US Dollar
+ USD
+ 840
+ 2
+
+
+ QATAR
+ Qatari Rial
+ QAR
+ 634
+ 2
+
+
+ RÉUNION
+ Euro
+ EUR
+ 978
+ 2
+
+
+ ROMANIA
+ New Romanian Leu
+ RON
+ 946
+ 2
+
+
+ RUSSIAN FEDERATION
+ Russian Ruble
+ RUB
+ 643
+ 2
+
+
+ RWANDA
+ Rwanda Franc
+ RWF
+ 646
+ 0
+
+
+ SAINT BARTHÉLEMY
+ Euro
+ EUR
+ 978
+ 2
+
+
+ SAINT HELENA, ASCENSION AND
+ TRISTAN DA CUNHA
+ Saint Helena Pound
+ SHP
+ 654
+ 2
+
+
+ SAINT KITTS AND NEVIS
+ East Caribbean Dollar
+ XCD
+ 951
+ 2
+
+
+ SAINT LUCIA
+ East Caribbean Dollar
+ XCD
+ 951
+ 2
+
+
+ SAINT MARTIN (FRENCH PART)
+ Euro
+ EUR
+ 978
+ 2
+
+
+ SAINT PIERRE AND MIQUELON
+ Euro
+ EUR
+ 978
+ 2
+
+
+ SAINT VINCENT AND THE GRENADINES
+ East Caribbean Dollar
+ XCD
+ 951
+ 2
+
+
+ SAMOA
+ Tala
+ WST
+ 882
+ 2
+
+
+ SAN MARINO
+ Euro
+ EUR
+ 978
+ 2
+
+
+ SAO TOME AND PRINCIPE
+ Dobra
+ STD
+ 678
+ 2
+
+
+ SAUDI ARABIA
+ Saudi Riyal
+ SAR
+ 682
+ 2
+
+
+ SENEGAL
+ CFA Franc BCEAO
+ XOF
+ 952
+ 0
+
+
+ SERBIA
+ Serbian Dinar
+ RSD
+ 941
+ 2
+
+
+ SEYCHELLES
+ Seychelles Rupee
+ SCR
+ 690
+ 2
+
+
+ SIERRA LEONE
+ Leone
+ SLL
+ 694
+ 2
+
+
+ SINGAPORE
+ Singapore Dollar
+ SGD
+ 702
+ 2
+
+
+ SINT MAARTEN (DUTCH PART)
+ Netherlands Antillean Guilder
+ ANG
+ 532
+ 2
+
+
+ SISTEMA UNITARIO DE COMPENSACION REGIONAL DE PAGOS "SUCRE"
+ Sucre
+ XSU
+ 994
+ N.A.
+
+
+ SLOVAKIA
+ Euro
+ EUR
+ 978
+ 2
+
+
+ SLOVENIA
+ Euro
+ EUR
+ 978
+ 2
+
+
+ SOLOMON ISLANDS
+ Solomon Islands Dollar
+ SBD
+ 090
+ 2
+
+
+ SOMALIA
+ Somali Shilling
+ SOS
+ 706
+ 2
+
+
+ SOUTH AFRICA
+ Rand
+ ZAR
+ 710
+ 2
+
+
+ SOUTH GEORGIA AND THE SOUTH SANDWICH ISLANDS
+ No universal currency
+
+
+ SOUTH SUDAN
+ South Sudanese Pound
+ SSP
+ 728
+ 2
+
+
+ SPAIN
+ Euro
+ EUR
+ 978
+ 2
+
+
+ SRI LANKA
+ Sri Lanka Rupee
+ LKR
+ 144
+ 2
+
+
+ SUDAN
+ Sudanese Pound
+ SDG
+ 938
+ 2
+
+
+ SURINAME
+ Surinam Dollar
+ SRD
+ 968
+ 2
+
+
+ SVALBARD AND JAN MAYEN
+ Norwegian Krone
+ NOK
+ 578
+ 2
+
+
+ SWAZILAND
+ Lilangeni
+ SZL
+ 748
+ 2
+
+
+ SWEDEN
+ Swedish Krona
+ SEK
+ 752
+ 2
+
+
+ SWITZERLAND
+ WIR Euro
+ CHE
+ 947
+ 2
+
+
+ SWITZERLAND
+ Swiss Franc
+ CHF
+ 756
+ 2
+
+
+ SWITZERLAND
+ WIR Franc
+ CHW
+ 948
+ 2
+
+
+ SYRIAN ARAB REPUBLIC
+ Syrian Pound
+ SYP
+ 760
+ 2
+
+
+ TAIWAN, PROVINCE OF CHINA
+ New Taiwan Dollar
+ TWD
+ 901
+ 2
+
+
+ TAJIKISTAN
+ Somoni
+ TJS
+ 972
+ 2
+
+
+ TANZANIA, UNITED REPUBLIC OF
+ Tanzanian Shilling
+ TZS
+ 834
+ 2
+
+
+ THAILAND
+ Baht
+ THB
+ 764
+ 2
+
+
+ TIMOR-LESTE
+ US Dollar
+ USD
+ 840
+ 2
+
+
+ TOGO
+ CFA Franc BCEAO
+ XOF
+ 952
+ 0
+
+
+ TOKELAU
+ New Zealand Dollar
+ NZD
+ 554
+ 2
+
+
+ TONGA
+ Pa’anga
+ TOP
+ 776
+ 2
+
+
+ TRINIDAD AND TOBAGO
+ Trinidad and Tobago Dollar
+ TTD
+ 780
+ 2
+
+
+ TUNISIA
+ Tunisian Dinar
+ TND
+ 788
+ 3
+
+
+ TURKEY
+ Turkish Lira
+ TRY
+ 949
+ 2
+
+
+ TURKMENISTAN
+ Turkmenistan New Manat
+ TMT
+ 934
+ 2
+
+
+ TURKS AND CAICOS ISLANDS
+ US Dollar
+ USD
+ 840
+ 2
+
+
+ TUVALU
+ Australian Dollar
+ AUD
+ 036
+ 2
+
+
+ UGANDA
+ Uganda Shilling
+ UGX
+ 800
+ 0
+
+
+ UKRAINE
+ Hryvnia
+ UAH
+ 980
+ 2
+
+
+ UNITED ARAB EMIRATES
+ UAE Dirham
+ AED
+ 784
+ 2
+
+
+ UNITED KINGDOM
+ Pound Sterling
+ GBP
+ 826
+ 2
+
+
+ UNITED STATES
+ US Dollar
+ USD
+ 840
+ 2
+
+
+ UNITED STATES
+ US Dollar (Next day)
+ USN
+ 997
+ 2
+
+
+ UNITED STATES MINOR OUTLYING ISLANDS
+ US Dollar
+ USD
+ 840
+ 2
+
+
+ URUGUAY
+ Uruguay Peso en Unidades Indexadas (URUIURUI)
+ UYI
+ 940
+ 0
+
+
+ URUGUAY
+ Peso Uruguayo
+ UYU
+ 858
+ 2
+
+
+ UZBEKISTAN
+ Uzbekistan Sum
+ UZS
+ 860
+ 2
+
+
+ VANUATU
+ Vatu
+ VUV
+ 548
+ 0
+
+
+ VENEZUELA, BOLIVARIAN REPUBLIC OF
+ Bolivar
+ VEF
+ 937
+ 2
+
+
+ VIET NAM
+ Dong
+ VND
+ 704
+ 0
+
+
+ VIRGIN ISLANDS (BRITISH)
+ US Dollar
+ USD
+ 840
+ 2
+
+
+ VIRGIN ISLANDS (U.S.)
+ US Dollar
+ USD
+ 840
+ 2
+
+
+ WALLIS AND FUTUNA
+ CFP Franc
+ XPF
+ 953
+ 0
+
+
+ WESTERN SAHARA
+ Moroccan Dirham
+ MAD
+ 504
+ 2
+
+
+ YEMEN
+ Yemeni Rial
+ YER
+ 886
+ 2
+
+
+ ZAMBIA
+ Zambian Kwacha
+ ZMW
+ 967
+ 2
+
+
+ ZIMBABWE
+ Zimbabwe Dollar
+ ZWL
+ 932
+ 2
+
+
+ ZZ01_Bond Markets Unit European_EURCO
+ Bond Markets Unit European Composite Unit (EURCO)
+ XBA
+ 955
+ N.A.
+
+
+ ZZ02_Bond Markets Unit European_EMU-6
+ Bond Markets Unit European Monetary Unit (E.M.U.-6)
+ XBB
+ 956
+ N.A.
+
+
+ ZZ03_Bond Markets Unit European_EUA-9
+ Bond Markets Unit European Unit of Account 9 (E.U.A.-9)
+ XBC
+ 957
+ N.A.
+
+
+ ZZ04_Bond Markets Unit European_EUA-17
+ Bond Markets Unit European Unit of Account 17 (E.U.A.-17)
+ XBD
+ 958
+ N.A.
+
+
+ ZZ06_Testing_Code
+ Codes specifically reserved for testing purposes
+ XTS
+ 963
+ N.A.
+
+
+ ZZ07_No_Currency
+ The codes assigned for transactions where no currency is involved
+ XXX
+ 999
+ N.A.
+
+
+ ZZ08_Gold
+ Gold
+ XAU
+ 959
+ N.A.
+
+
+ ZZ09_Palladium
+ Palladium
+ XPD
+ 964
+ N.A.
+
+
+ ZZ10_Platinum
+ Platinum
+ XPT
+ 962
+ N.A.
+
+
+ ZZ11_Silver
+ Silver
+ XAG
+ 961
+ N.A.
+
+
\ No newline at end of file
diff --git a/local/modules/Paybox/Config/module.xml b/local/modules/Paybox/Config/module.xml
index ebb5ee1f..fc302775 100644
--- a/local/modules/Paybox/Config/module.xml
+++ b/local/modules/Paybox/Config/module.xml
@@ -1,18 +1,18 @@
-
-
- Paybox\Paybox
-
- Pay with credit card using Paybox
-
-
- Paiement en carte bancaire avec Paybox
-
- 1.0.0
-
- Franck Allimant
- franck@cqfdev.fr
-
- payment
- 2.1.0
- prod
-
+
+
+ Paybox\Paybox
+
+ Pay with credit card using Paybox
+
+
+ Paiement en carte bancaire avec Paybox
+
+ 1.2.5
+
+ Franck Allimant
+ franck@cqfdev.fr
+
+ payment
+ 2.1.0
+ prod
+
diff --git a/local/modules/Paybox/Controller/_notes/dwsync.xml b/local/modules/Paybox/Controller/_notes/dwsync.xml
deleted file mode 100644
index 8f762ac6..00000000
--- a/local/modules/Paybox/Controller/_notes/dwsync.xml
+++ /dev/null
@@ -1,5 +0,0 @@
-
-
-
-
-
\ No newline at end of file
diff --git a/local/modules/Paybox/EventListener/_notes/dwsync.xml b/local/modules/Paybox/EventListener/_notes/dwsync.xml
deleted file mode 100644
index 845ac904..00000000
--- a/local/modules/Paybox/EventListener/_notes/dwsync.xml
+++ /dev/null
@@ -1,4 +0,0 @@
-
-
-
-
\ No newline at end of file
diff --git a/local/modules/Paybox/Form/_notes/dwsync.xml b/local/modules/Paybox/Form/_notes/dwsync.xml
deleted file mode 100644
index 69e549ec..00000000
--- a/local/modules/Paybox/Form/_notes/dwsync.xml
+++ /dev/null
@@ -1,4 +0,0 @@
-
-
-
-
\ No newline at end of file
diff --git a/local/modules/Paybox/I18n/AdminIncludes/_notes/dwsync.xml b/local/modules/Paybox/I18n/AdminIncludes/_notes/dwsync.xml
deleted file mode 100644
index b0d10f4c..00000000
--- a/local/modules/Paybox/I18n/AdminIncludes/_notes/dwsync.xml
+++ /dev/null
@@ -1,5 +0,0 @@
-
-
-
-
-
\ No newline at end of file
diff --git a/local/modules/Paybox/I18n/AdminIncludes/fr_FR.php b/local/modules/Paybox/I18n/AdminIncludes/fr_FR.php
index f28819d2..4e89715c 100644
--- a/local/modules/Paybox/I18n/AdminIncludes/fr_FR.php
+++ b/local/modules/Paybox/I18n/AdminIncludes/fr_FR.php
@@ -1,35 +1,35 @@
-
-
- L\'interface de génération de la clé secrète d\'authentification se trouve dans l\'onglet "Informations" du Back Office Commerçant de Paybox, en bas de la page.
-
-
- Le champ "Phrase de passe" peut être renseigné avec une phrase, un mot de passe, ou tout autre texte.
-
-
- L\'affichage par défaut du champ "Phrase de passe" est caché, les caractères apparaissent comme un champ "mot de passe". Il est possible de choisir d\'afficher cette phrase de passe en décochant la case "Cacher".
-
-
- Les champs "Complexité" et "Force" sont mis à jour automatiquement lorsque la phrase de passe est saisie. Ces champs permettent de définir des règles d\'acceptation minimales de la phrase de passe. Les règles fixées actuellement demandent une phrase de passe d\'au moins 15 caractères de long et d\'une force de 90%. Le bouton "VALIDER" restera grisé tant que ces limitations ne sont pas respectées.
-
-
- Le bouton "Générer une clé" permet de calculer la clé d\'authentification à partir de la phrase de passe saisie. Ce calcul est une méthode standard assurant le caractère aléatoire de la clé et renforçant sa robustesse. Cette méthode de calcul étant fixe, il est possible à tout moment de retrouver sa clé en retapant la même phrase de passe et en relançant le calcul.
- Attention, il est possible que le calcul de la clé prenne quelques secondes, selon le navigateur Internet utilisé et la puissance de l\'ordinateur. Au cours du calcul, il se peut que votre navigateur demande s\'il faut "arrêter l\'exécution de ce script". Il faut répondre "Non" à cette alerte, et patienter jusqu\'à la fin du calcul.
-
-
- Après validation du formulaire, un message récapitulatif sera affiché sur la page, expliquant qu\'un email de demande de confirmation a été envoyé à l\'adresse mail du Commerçant. La clé qui vient d\'être générée ne sera pas active tant que les indications de validation décrites dans cet email n\'auront pas été appliquées.
-
-
- Il faut alors copier la clé d\'authentification qui se trouve dans le champ "Clé", et la coller dans le champ "Clef privée d\'échange" de la page de configuration du module Paybox (back office de Thelia -> Modules -> Paybox -> Configurer)
-
- ' => ' - L\'interface de génération de la clé secrète d\'authentification se trouve dans l\'onglet "Informations" du Back Office Commerçant de Paybox, en bas de la page.
- Le champ "Phrase de passe" peut être renseigné avec une phrase, un mot de passe, ou tout autre texte.
- L\'affichage par défaut du champ "Phrase de passe" est caché, les caractères apparaissent comme un champ "mot de passe". Il est possible de choisir d\'afficher cette phrase de passe en décochant la case "Cacher".
- Les champs "Complexité" et "Force" sont mis à jour automatiquement lorsque la phrase de passe est saisie. Ces champs permettent de définir des règles d\'acceptation minimales de la phrase de passe. Les règles fixées actuellement demandent une phrase de passe d\'au moins 15 caractères de long et d\'une force de 90%. Le bouton "VALIDER" restera grisé tant que ces limitations ne sont pas respectées.
- Le bouton "Générer une clé" permet de calculer la clé d\'authentification à partir de la phrase de passe saisie. Ce calcul est une méthode standard assurant le caractère aléatoire de la clé et renforçant sa robustesse. Cette méthode de calcul étant fixe, il est possible à tout moment de retrouver sa clé en retapant la même phrase de passe et en relançant le calcul.
Attention, il est possible que le calcul de la clé prenne quelques secondes, selon le navigateur Internet utilisé et la puissance de l\'ordinateur. Au cours du calcul, il se peut que votre navigateur demande s\'il faut "arrêter l\'exécution de ce script". Il faut répondre "Non" à cette alerte, et patienter jusqu\'à la fin du calcul. - Après validation du formulaire, un message récapitulatif sera affiché sur la page, expliquant qu\'un email de demande de confirmation a été envoyé à l\'adresse mail du Commerçant. La clé qui vient d\'être générée ne sera pas active tant que les indications de validation décrites dans cet email n\'auront pas été appliquées.
- Il faut alors copier la clé d\'authentification qui se trouve dans le champ "Clé", et la coller dans le champ "Clef privée d\'échange" de la page de configuration du module Paybox (back office de Thelia -> Modules -> Paybox -> Configurer)
',
- 'Accès à la plate-forme Paybox' => 'Accès à la plate-forme Paybox',
- 'Comment générer votre clef privée ?' => 'Comment générer votre clef privée ?',
- 'Configuration des URLs' => 'Configuration des URLs',
- 'Configuration du paiement' => 'Configuration du paiement',
- 'Historique des appels Paybox à l\'URL IPN' => 'Historique des appels Paybox à l\'URL IPN',
- 'Paybox Configuration' => 'Configuration Paybox',
- 'Vous pouvez aussi configurer le mail de confirmation Paybox' => 'Vous pouvez aussi configurer le mail de confirmation Paybox',
-);
+
+
+ L\'interface de génération de la clé secrète d\'authentification se trouve dans l\'onglet "Informations" du Back Office Commerçant de Paybox, en bas de la page.
+
+
+ Le champ "Phrase de passe" peut être renseigné avec une phrase, un mot de passe, ou tout autre texte.
+
+
+ L\'affichage par défaut du champ "Phrase de passe" est caché, les caractères apparaissent comme un champ "mot de passe". Il est possible de choisir d\'afficher cette phrase de passe en décochant la case "Cacher".
+
+
+ Les champs "Complexité" et "Force" sont mis à jour automatiquement lorsque la phrase de passe est saisie. Ces champs permettent de définir des règles d\'acceptation minimales de la phrase de passe. Les règles fixées actuellement demandent une phrase de passe d\'au moins 15 caractères de long et d\'une force de 90%. Le bouton "VALIDER" restera grisé tant que ces limitations ne sont pas respectées.
+
+
+ Le bouton "Générer une clé" permet de calculer la clé d\'authentification à partir de la phrase de passe saisie. Ce calcul est une méthode standard assurant le caractère aléatoire de la clé et renforçant sa robustesse. Cette méthode de calcul étant fixe, il est possible à tout moment de retrouver sa clé en retapant la même phrase de passe et en relançant le calcul.
+ Attention, il est possible que le calcul de la clé prenne quelques secondes, selon le navigateur Internet utilisé et la puissance de l\'ordinateur. Au cours du calcul, il se peut que votre navigateur demande s\'il faut "arrêter l\'exécution de ce script". Il faut répondre "Non" à cette alerte, et patienter jusqu\'à la fin du calcul.
+
+
+ Après validation du formulaire, un message récapitulatif sera affiché sur la page, expliquant qu\'un email de demande de confirmation a été envoyé à l\'adresse mail du Commerçant. La clé qui vient d\'être générée ne sera pas active tant que les indications de validation décrites dans cet email n\'auront pas été appliquées.
+
+
+ Il faut alors copier la clé d\'authentification qui se trouve dans le champ "Clé", et la coller dans le champ "Clef privée d\'échange" de la page de configuration du module Paybox (back office de Thelia -> Modules -> Paybox -> Configurer)
+
+ ' => ' - L\'interface de génération de la clé secrète d\'authentification se trouve dans l\'onglet "Informations" du Back Office Commerçant de Paybox, en bas de la page.
- Le champ "Phrase de passe" peut être renseigné avec une phrase, un mot de passe, ou tout autre texte.
- L\'affichage par défaut du champ "Phrase de passe" est caché, les caractères apparaissent comme un champ "mot de passe". Il est possible de choisir d\'afficher cette phrase de passe en décochant la case "Cacher".
- Les champs "Complexité" et "Force" sont mis à jour automatiquement lorsque la phrase de passe est saisie. Ces champs permettent de définir des règles d\'acceptation minimales de la phrase de passe. Les règles fixées actuellement demandent une phrase de passe d\'au moins 15 caractères de long et d\'une force de 90%. Le bouton "VALIDER" restera grisé tant que ces limitations ne sont pas respectées.
- Le bouton "Générer une clé" permet de calculer la clé d\'authentification à partir de la phrase de passe saisie. Ce calcul est une méthode standard assurant le caractère aléatoire de la clé et renforçant sa robustesse. Cette méthode de calcul étant fixe, il est possible à tout moment de retrouver sa clé en retapant la même phrase de passe et en relançant le calcul.
Attention, il est possible que le calcul de la clé prenne quelques secondes, selon le navigateur Internet utilisé et la puissance de l\'ordinateur. Au cours du calcul, il se peut que votre navigateur demande s\'il faut "arrêter l\'exécution de ce script". Il faut répondre "Non" à cette alerte, et patienter jusqu\'à la fin du calcul. - Après validation du formulaire, un message récapitulatif sera affiché sur la page, expliquant qu\'un email de demande de confirmation a été envoyé à l\'adresse mail du Commerçant. La clé qui vient d\'être générée ne sera pas active tant que les indications de validation décrites dans cet email n\'auront pas été appliquées.
- Il faut alors copier la clé d\'authentification qui se trouve dans le champ "Clé", et la coller dans le champ "Clef privée d\'échange" de la page de configuration du module Paybox (back office de Thelia -> Modules -> Paybox -> Configurer)
',
+ 'Accès à la plate-forme Paybox' => 'Accès à la plate-forme Paybox',
+ 'Comment générer votre clef privée ?' => 'Comment générer votre clef privée ?',
+ 'Configuration des URLs' => 'Configuration des URLs',
+ 'Configuration du paiement' => 'Configuration du paiement',
+ 'Historique des appels Paybox à l\'URL IPN' => 'Historique des appels Paybox à l\'URL IPN',
+ 'Paybox Configuration' => 'Configuration Paybox',
+ 'Vous pouvez aussi configurer le mail de confirmation Paybox' => 'Vous pouvez aussi configurer le mail de confirmation Paybox',
+);
diff --git a/local/modules/Paybox/I18n/_notes/dwsync.xml b/local/modules/Paybox/I18n/_notes/dwsync.xml
deleted file mode 100644
index b0d10f4c..00000000
--- a/local/modules/Paybox/I18n/_notes/dwsync.xml
+++ /dev/null
@@ -1,5 +0,0 @@
-
-
-
-
-
\ No newline at end of file
diff --git a/local/modules/Paybox/I18n/backOffice/default/_notes/dwsync.xml b/local/modules/Paybox/I18n/backOffice/default/_notes/dwsync.xml
deleted file mode 100644
index f4e532a8..00000000
--- a/local/modules/Paybox/I18n/backOffice/default/_notes/dwsync.xml
+++ /dev/null
@@ -1,4 +0,0 @@
-
-
-
-
\ No newline at end of file
diff --git a/local/modules/Paybox/I18n/backOffice/default/fr_FR.php b/local/modules/Paybox/I18n/backOffice/default/fr_FR.php
index 792b1a92..1cd85e72 100644
--- a/local/modules/Paybox/I18n/backOffice/default/fr_FR.php
+++ b/local/modules/Paybox/I18n/backOffice/default/fr_FR.php
@@ -1,6 +1,6 @@
- 'Le type de champ \'%type\' n\'est pas pris en charge par form-field-template.html',
- 'Use Ctrl+click to select (or deselect) more that one item' => 'Utilisez Ctrl+clic pour sélectionner ou désélectionner un élément',
-);
+ 'Le type de champ \'%type\' n\'est pas pris en charge par form-field-template.html',
+ 'Use Ctrl+click to select (or deselect) more that one item' => 'Utilisez Ctrl+clic pour sélectionner ou désélectionner un élément',
+);
diff --git a/local/modules/Paybox/I18n/email-templates/_notes/dwsync.xml b/local/modules/Paybox/I18n/email-templates/_notes/dwsync.xml
deleted file mode 100644
index fd278bb8..00000000
--- a/local/modules/Paybox/I18n/email-templates/_notes/dwsync.xml
+++ /dev/null
@@ -1,11 +0,0 @@
-
-
-
-
-
-
-
-
-
-
-
\ No newline at end of file
diff --git a/local/modules/Paybox/I18n/en_US.php b/local/modules/Paybox/I18n/en_US.php
index 5c1cef6d..5da0144f 100644
--- a/local/modules/Paybox/I18n/en_US.php
+++ b/local/modules/Paybox/I18n/en_US.php
@@ -12,6 +12,7 @@ return array(
'Failed to open %file, please check Paybox configuration' => 'Failed to open %file, please check Paybox configuration',
'Identifiant interne' => 'Internal identifier',
'Identifiant interne, tel que fourni par Paybox' => 'Internal identifier, provided by Paybox',
+ 'Invalid phone number %num for country %country' => 'Invalid phone number %num for country %country',
'Le fichier de log est vide.' => 'The log file is empty.',
'Le fichier de log n\'a pas été trouvé.' => 'The log file could not be found.',
'Maximum order total' => 'Maximum order total',
@@ -32,6 +33,7 @@ return array(
'Paybox configuration' => 'Paybox configuration',
'Paybox platform request processing terminated.' => 'Paybox platform request processing terminated.',
'Paybox platform request received.' => 'Paybox platform request received.',
+ 'Please enter a valid phone number in your invoice address (error is : %err)' => 'Please enter a valid phone number in your invoice address (error is : %err)',
'Production' => 'Production',
'Request parameters signature verification failed.' => 'Request parameters signature verification failed.',
'Test' => 'Test',
diff --git a/local/modules/Paybox/I18n/fr_FR.php b/local/modules/Paybox/I18n/fr_FR.php
index c662e0a4..55432fb8 100644
--- a/local/modules/Paybox/I18n/fr_FR.php
+++ b/local/modules/Paybox/I18n/fr_FR.php
@@ -12,6 +12,7 @@ return array(
'Failed to open %file, please check Paybox configuration' => 'Le fichier %file est inaccessible, merci de vérifier la configuration Paybox',
'Identifiant interne' => 'Identifiant interne',
'Identifiant interne, tel que fourni par Paybox' => 'Identifiant interne, tel que fourni par Paybox',
+ 'Invalid phone number %num for country %country' => 'Le numéro de téléphone %num est invalide pour le pays %country',
'Le fichier de log est vide.' => 'Le fichier de log est vide.',
'Le fichier de log n\'a pas été trouvé.' => 'Le fichier de log n\'a pas été trouvé.',
'Maximum order total' => 'Montant de commande maximum',
@@ -32,6 +33,7 @@ return array(
'Paybox configuration' => 'Configuration Paybox',
'Paybox platform request processing terminated.' => 'Traitement de la requête Paybox terminé.',
'Paybox platform request received.' => 'Réception d\'une requête de la plate-form Paybox',
+ 'Please enter a valid phone number in your invoice address (error is : %err)' => 'Merci d\'entrer un numero de téléphone mobile valide dans votre adresse de facturation (détail de l\'erreur : %err)',
'Production' => 'Production',
'Request parameters signature verification failed.' => 'La vérification de la signature de la requête a échoué.',
'Test' => 'Test',
diff --git a/local/modules/Paybox/Paybox.php b/local/modules/Paybox/Paybox.php
index 935d28d0..af0afcc8 100644
--- a/local/modules/Paybox/Paybox.php
+++ b/local/modules/Paybox/Paybox.php
@@ -1,340 +1,420 @@
-
- */
-class Paybox extends AbstractPaymentModule
-{
- /** The module domain for internationalisation */
- const MODULE_DOMAIN = "paybox";
-
- /** The module domain for internationalisation */
- const MODULE_CODE = "Paybox";
-
- /** The confirmation message identifier */
- const CONFIRMATION_MESSAGE_NAME = 'paybox_payment_confirmation';
-
- // Liste des variables retournées par paybox
- const PARAMETRES_RETOUR = 'montant:M;ref:R;auto:A;trans:T;erreur:E;sign:K';
-
- /** The notification of payment confirmation */
- const NOTIFICATION_MESSAGE_NAME = 'paybox_payment_status_notification';
-
- /**
- * @inheritdoc
- */
- public function postActivation(ConnectionInterface $con = null)
- {
- // Create payment confirmation message from templates, if not already defined
- $email_templates_dir = __DIR__ . DS . 'I18n' . DS . 'email-templates' . DS;
-
- if (null === MessageQuery::create()->findOneByName(self::CONFIRMATION_MESSAGE_NAME)) {
- $message = new Message();
-
- $message
- ->setName(self::CONFIRMATION_MESSAGE_NAME)
-
- ->setLocale('en_US')
- ->setTitle('Paybox payment confirmation')
- ->setSubject('Payment of order {$order_ref}')
- ->setHtmlMessage(file_get_contents($email_templates_dir . 'en.html'))
- ->setTextMessage(file_get_contents($email_templates_dir . 'en.txt'))
-
- ->setLocale('fr_FR')
- ->setTitle('Confirmation de paiement par PayBox')
- ->setSubject('Confirmation du paiement de votre commande {$order_ref}')
- ->setHtmlMessage(file_get_contents($email_templates_dir . 'fr.html'))
- ->setTextMessage(file_get_contents($email_templates_dir . 'fr.txt'))
- ->save();
- }
-
- if (null === MessageQuery::create()->findOneByName(self::NOTIFICATION_MESSAGE_NAME)) {
- $message = new Message();
-
- $message
- ->setName(self::NOTIFICATION_MESSAGE_NAME)
-
- ->setLocale('en_US')
- ->setTitle('Paybox payment status notification')
- ->setSubject('Paybox payment status for order {$order_ref}: {$paybox_payment_status}')
- ->setHtmlMessage(file_get_contents($email_templates_dir . 'notification-en.html'))
- ->setTextMessage(file_get_contents($email_templates_dir . 'notification-en.txt'))
-
- ->setLocale('fr_FR')
- ->setTitle('Notification du résultat d\'un paiement par Paybox')
- ->setSubject('Résultats du paiement Paybox de la commande {$order_ref} : {$paybox_payment_status}')
- ->setHtmlMessage(file_get_contents($email_templates_dir . 'notification-fr.html'))
- ->setTextMessage(file_get_contents($email_templates_dir . 'notification-fr.txt'))
- ->save();
- }
-
- /* Deploy the module's image */
$module = $this->getModuleModel();
if (ModuleImageQuery::create()->filterByModule($module)->count() == 0) {
$this->deployImageFolder($module, sprintf('%s/images', __DIR__), $con);
}
- }
-
- /**
- * @inheritdoc
- */
- public function destroy(ConnectionInterface $con = null, $deleteModuleData = false)
- {
- // Delete config table and messages if required
- if ($deleteModuleData) {
- MessageQuery::create()->findOneByName(self::CONFIRMATION_MESSAGE_NAME)->delete($con);
- MessageQuery::create()->findOneByName(self::NOTIFICATION_MESSAGE_NAME)->delete($con);
- }
- }
-
- /**
- * Method used by payment gateway.
- *
- * If this method return a \Thelia\Core\HttpFoundation\Response instance, this response is sent to the
- * browser.
- *
- * In many cases, it's necessary to send a form to the payment gateway.
- * On your response you can return this form already completed, ready to be sent
- *
- * @param Order $order processed order
- * @return Response the HTTP response
- */
- public function pay(Order $order)
- {
- return $this->doPay($order, 'SINGLE');
- }
-
- /**
- * Payment gateway invocation
- *
- * @param Order $order processed order
- * @return Response the HTTP response
- */
- protected function doPay(Order $order)
- {
- if ('TEST' == Paybox::getConfigValue('mode', false)) {
- $platformUrl = Paybox::getConfigValue('url_serveur_test', false);
- } else {
- $platformUrl = Paybox::getConfigValue('url_serveur', false);
- }
-
- // Be sure to have a valid platform URL, otherwise give up
- if (false === $platformUrl) {
- throw new \InvalidArgumentException(
- Translator::getInstance()->trans(
- "The platform URL is not defined, please check Paybox module configuration.",
- [],
- Paybox::MODULE_DOMAIN
- )
- );
- }
-
- $hashAlgo = $this->getHashAlgorithm();
- $clefPrivee = Paybox::getConfigValue('clef_privee');
-
- // Generate a transaction ID
- $transactionId = sprintf("%010d", $order->getId());
-
- $order->setTransactionRef($transactionId)->save();
-
- $paybox_params = [
- 'PBX_SITE' => Paybox::getConfigValue('numero_site'),
- 'PBX_RANG' => Paybox::getConfigValue('rang_site'),
- 'PBX_IDENTIFIANT' => Paybox::getConfigValue('identifiant_interne'),
- 'PBX_RETOUR' => self::PARAMETRES_RETOUR,
- 'PBX_HASH' => $hashAlgo,
- 'PBX_SECRET' => $clefPrivee,
- 'PBX_ANNULE' => Paybox::getConfigValue('url_retour_abandon'),
- 'PBX_EFFECTUE' => Paybox::getConfigValue('url_retour_succes'),
- 'PBX_REFUSE' => Paybox::getConfigValue('url_retour_refus'),
- 'PBX_REPONDRE_A' => Paybox::getConfigValue('url_ipn'),
- 'PBX_TOTAL' => round(100 * $order->getTotalAmount()),
- 'PBX_DEVISE' => $this->getCurrencyIso4217NumericCode($order->getCurrency()->getCode()),
- 'PBX_CMD' => $transactionId,
- 'PBX_PORTEUR' => $order->getCustomer()->getEmail(),
- 'PBX_TIME' => date("c"),
- 'PBX_RUF1' => 'POST'
- ];
-
- // Generate signature
- $param = '';
-
- foreach ($paybox_params as $key => $value) {
- $param .= "&" . $key . '=' . $value;
- }
-
- $param = ltrim($param, '&');
-
- $binkey = pack('H*', $clefPrivee);
-
- $paybox_params['PBX_HMAC'] = strtoupper(hash_hmac($hashAlgo, $param, $binkey));
-
- return $this->generateGatewayFormResponse($order, $platformUrl, $paybox_params);
- }
-
- /**
- * @return boolean true to allow usage of this payment module, false otherwise.
- */
- public function isValidPayment()
- {
- $valid = false;
-
- $mode = Paybox::getConfigValue('mode', false);
-
- // If we're in test mode, do not display Paybox on the front office, except for allowed IP addresses.
- if ('TEST' == $mode) {
- $raw_ips = explode("\n", Paybox::getConfigValue('allowed_ip_list', ''));
-
- $allowed_client_ips = array();
-
- foreach ($raw_ips as $ip) {
- $allowed_client_ips[] = trim($ip);
- }
-
- $client_ip = $this->getRequest()->getClientIp();
-
- $valid = in_array($client_ip, $allowed_client_ips);
- } elseif ('PRODUCTION' == $mode) {
- $valid = true;
- }
-
- if ($valid) {
- // Check if total order amount is in the module's limits
- $valid = $this->checkMinMaxAmount();
- }
-
- return $valid;
- }
-
- /**
- * Check if total order amount is in the module's limits
- *
- * @return bool true if the current order total is within the min and max limits
- */
- protected function checkMinMaxAmount()
- {
- // Check if total order amount is in the module's limits
- $order_total = $this->getCurrentOrderTotalAmount();
-
- $min_amount = Paybox::getConfigValue('minimum_amount', 0);
- $max_amount = Paybox::getConfigValue('maximum_amount', 0);
-
- return $order_total > 0
- &&
- ($min_amount <= 0 || $order_total >= $min_amount)
- &&
- ($max_amount <= 0 || $order_total <= $max_amount);
- }
-
- /**
- * Get the numeric ISO 4217 code of a currency
- *
- * @param string $textCurrencyCode currency textual code, like EUR or USD
- * @return string the algorithm
- * @throw \RuntimeException if no algorithm was found.
- */
-
- protected function getCurrencyIso4217NumericCode($textCurrencyCode)
- {
- $currencies = null;
-
- $localIso417data = __DIR__ . DS . "Config" . DS . "iso4217.xml";
-
- $currencyXmlDataUrl = "http://www.currency-iso.org/dam/downloads/lists/list_one.xml";
-
- $xmlData = @file_get_contents($currencyXmlDataUrl);
-
- try {
- $currencies = new \SimpleXMLElement($xmlData);
-
- // Update the local currencies copy.
- @file_put_contents($localIso417data, $xmlData);
- } catch (\Exception $ex) {
- Tlog::getInstance()->warning("Failed to get currency XML data from $currencyXmlDataUrl: ".$ex->getMessage());
- try {
- $currencies = new \SimpleXMLElement(@file_get_contents($localIso417data));
- } catch (\Exception $ex) {
- Tlog::getInstance()->warning("Failed to get currency XML data from local copy $localIso417data: ".$ex->getMessage());
- }
- }
-
- if (null !== $currencies) {
- foreach ($currencies->CcyTbl->CcyNtry as $country) {
- if ($country->Ccy == $textCurrencyCode) {
- return (string) $country->CcyNbr;
- }
- }
- }
-
- // Last chance
- switch ($textCurrencyCode) {
- case 'USD':
- return 840;
- case 'GBP':
- return 826;
- break;
- case 'EUR':
- return 978;
- break;
- }
-
- throw new \RuntimeException(
- Translator::getInstance()->trans(
- "Failed to get ISO 4217 data for currency %curr, payment is not possible.",
- ['%curr' => $textCurrencyCode]
- )
- );
- }
-
- /**
- * Find a suitable hashing algorithm
- *
- * @return string the algorithm
- * @throw \RuntimeException if no algorithm was found.
- */
- protected function getHashAlgorithm()
- {
- // Possible hashes
- $hashes = [
- 'sha512',
- 'sha256',
- 'sha384',
- 'ripemd160',
- 'sha224',
- 'mdc2'
- ];
-
- $hashEnabled = hash_algos();
-
- foreach ($hashes as $hash) {
- if (in_array($hash, $hashEnabled)) {
- return strtoupper($hash);
- }
- }
-
- throw new \RuntimeException(
- Translator::getInstance()->trans(
- "Failed to find a suitable hash algorithm. Please check your PHP configuration."
- )
- );
- }
-}
+
+ *
+ * For the full copyright and license information, please view the LICENSE
+ * file that was distributed with this source code.
+ */
+
+/* Copyright (c) CQFDev */
+/* email : thelia@cqfdev.fr */
+/* web : http://www.cqfdev.fr */
+
+namespace Paybox;
+
+use libphonenumber\NumberParseException;
+use libphonenumber\PhoneNumberUtil;
+use Propel\Runtime\Connection\ConnectionInterface;
+use Propel\Runtime\Exception\PropelException;
+use Thelia\Core\HttpFoundation\Response;
+use Thelia\Core\Translation\Translator;
+use Thelia\Log\Tlog;
+use Thelia\Model\Message;
+use Thelia\Model\MessageQuery;
+use Thelia\Model\ModuleImageQuery;
+use Thelia\Model\Order;
+use Thelia\Module\AbstractPaymentModule;
+
+/**
+ * Paybox payment module.
+ *
+ * @author Franck Allimant
+ */
+class Paybox extends AbstractPaymentModule
+{
+ /** The module domain for internationalisation */
+ const MODULE_DOMAIN = 'paybox';
+
+ /** The module domain for internationalisation */
+ const MODULE_CODE = 'Paybox';
+
+ /** The confirmation message identifier */
+ const CONFIRMATION_MESSAGE_NAME = 'paybox_payment_confirmation';
+
+ // Liste des variables retournées par paybox
+ const PARAMETRES_RETOUR = 'montant:M;ref:R;auto:A;trans:T;erreur:E;sign:K';
+
+ /** The notification of payment confirmation */
+ const NOTIFICATION_MESSAGE_NAME = 'paybox_payment_status_notification';
+
+ public function postActivation(ConnectionInterface $con = null): void
+ {
+ // Create payment confirmation message from templates, if not already defined
+ $email_templates_dir = __DIR__.DS.'I18n'.DS.'email-templates'.DS;
+
+ if (null === MessageQuery::create()->findOneByName(self::CONFIRMATION_MESSAGE_NAME)) {
+ $message = new Message();
+
+ $message
+ ->setName(self::CONFIRMATION_MESSAGE_NAME)
+
+ ->setLocale('en_US')
+ ->setTitle('Paybox payment confirmation')
+ ->setSubject('Payment of order {$order_ref}')
+ ->setHtmlMessage(file_get_contents($email_templates_dir.'en.html'))
+ ->setTextMessage(file_get_contents($email_templates_dir.'en.txt'))
+
+ ->setLocale('fr_FR')
+ ->setTitle('Confirmation de paiement par PayBox')
+ ->setSubject('Confirmation du paiement de votre commande {$order_ref}')
+ ->setHtmlMessage(file_get_contents($email_templates_dir.'fr.html'))
+ ->setTextMessage(file_get_contents($email_templates_dir.'fr.txt'))
+ ->save();
+ }
+
+ if (null === MessageQuery::create()->findOneByName(self::NOTIFICATION_MESSAGE_NAME)) {
+ $message = new Message();
+
+ $message
+ ->setName(self::NOTIFICATION_MESSAGE_NAME)
+
+ ->setLocale('en_US')
+ ->setTitle('Paybox payment status notification')
+ ->setSubject('Paybox payment status for order {$order_ref}: {$paybox_payment_status}')
+ ->setHtmlMessage(file_get_contents($email_templates_dir.'notification-en.html'))
+ ->setTextMessage(file_get_contents($email_templates_dir.'notification-en.txt'))
+
+ ->setLocale('fr_FR')
+ ->setTitle('Notification du résultat d\'un paiement par Paybox')
+ ->setSubject('Résultats du paiement Paybox de la commande {$order_ref} : {$paybox_payment_status}')
+ ->setHtmlMessage(file_get_contents($email_templates_dir.'notification-fr.html'))
+ ->setTextMessage(file_get_contents($email_templates_dir.'notification-fr.txt'))
+ ->save();
+ }
+
+ /* Deploy the module's image */
+ $module = $this->getModuleModel();
+
+ if (ModuleImageQuery::create()->filterByModule($module)->count() == 0) {
+ $this->deployImageFolder($module, sprintf('%s'.DS.'images', __DIR__), $con);
+ }
+ }
+
+ public function destroy(ConnectionInterface $con = null, $deleteModuleData = false): void
+ {
+ // Delete config table and messages if required
+ if ($deleteModuleData) {
+ MessageQuery::create()->findOneByName(self::CONFIRMATION_MESSAGE_NAME)->delete($con);
+ MessageQuery::create()->findOneByName(self::NOTIFICATION_MESSAGE_NAME)->delete($con);
+ }
+ }
+
+ /**
+ * Method used by payment gateway.
+ *
+ * If this method return a \Thelia\Core\HttpFoundation\Response instance, this response is sent to the
+ * browser.
+ *
+ * In many cases, it's necessary to send a form to the payment gateway.
+ * On your response you can return this form already completed, ready to be sent
+ *
+ * @param Order $order processed order
+ *
+ * @return Response the HTTP response
+ */
+ public function pay(Order $order): Response
+ {
+ return $this->doPay($order);
+ }
+
+ /**
+ * Payment gateway invocation.
+ *
+ * @param Order $order processed order
+ *
+ * @return Response the HTTP response
+ */
+ protected function doPay(Order $order): Response
+ {
+ if ('TEST' === self::getConfigValue('mode', false)) {
+ $platformUrl = self::getConfigValue('url_serveur_test', false);
+ } else {
+ $platformUrl = self::getConfigValue('url_serveur', false);
+ }
+
+ // Be sure to have a valid platform URL, otherwise give up
+ if (false === $platformUrl) {
+ throw new \InvalidArgumentException(
+ Translator::getInstance()->trans(
+ 'The platform URL is not defined, please check Paybox module configuration.',
+ [],
+ self::MODULE_DOMAIN
+ )
+ );
+ }
+
+ $hashAlgo = $this->getHashAlgorithm();
+ $clefPrivee = self::getConfigValue('clef_privee');
+
+ $paybox_params = $this->doPayPayboxParameters($order)
+ + [
+ 'PBX_HASH' => $hashAlgo,
+ 'PBX_SECRET' => $clefPrivee,
+ ];
+
+ // Generate signature
+ $param = '';
+
+ foreach ($paybox_params as $key => $value) {
+ $param .= '&'.$key.'='.$value;
+ }
+
+ $param = ltrim($param, '&');
+
+ $binkey = pack('H*', $clefPrivee);
+
+ $paybox_params['PBX_HMAC'] = strtoupper(hash_hmac($hashAlgo, $param, $binkey));
+
+ return $this->generateGatewayFormResponse($order, $platformUrl, $paybox_params);
+ }
+
+ protected function doPayPayboxParameters(Order $order): array
+ {
+ // Generate a transaction ID
+ $transactionId = sprintf('%010d', $order->getId());
+
+ $order->setTransactionRef($transactionId)->save();
+
+ $paybox_params = [
+ 'PBX_SITE' => self::getConfigValue('numero_site'),
+ 'PBX_RANG' => self::getConfigValue('rang_site'),
+ 'PBX_IDENTIFIANT' => self::getConfigValue('identifiant_interne'),
+ 'PBX_RETOUR' => self::PARAMETRES_RETOUR,
+ 'PBX_ANNULE' => self::getConfigValue('url_retour_abandon'),
+ 'PBX_EFFECTUE' => self::getConfigValue('url_retour_succes'),
+ 'PBX_REFUSE' => self::getConfigValue('url_retour_refus'),
+ 'PBX_REPONDRE_A' => self::getConfigValue('url_ipn'),
+ 'PBX_TOTAL' => round(100 * $order->getTotalAmount()),
+ 'PBX_DEVISE' => $this->getCurrencyIso4217NumericCode($order->getCurrency()->getCode()),
+ 'PBX_CMD' => $transactionId,
+ 'PBX_PORTEUR' => $order->getCustomer()->getEmail(),
+ 'PBX_TIME' => date('c'),
+ 'PBX_RUF1' => 'POST',
+ 'PBX_SHOPPINGCART' => $this->getShoppingCart($order),
+ 'PBX_BILLING' => $this->getBilling($order),
+ ];
+
+ return $paybox_params;
+ }
+
+ /**
+ * @throws PropelException
+ *
+ * @return array|bool|string|string[]
+ */
+ protected function getBilling(Order $order)
+ {
+ $address = $order->getOrderAddressRelatedByInvoiceOrderAddressId();
+
+ // Decode phone number
+ $phoneNumber = empty($address->getCellphone()) ? $address->getPhone() : $address->getCellphone();
+
+ $phoneUtil = PhoneNumberUtil::getInstance();
+
+ // Default values
+ $phoneCountryCode = '00';
+ $phoneNationalNumber = '00000000';
+
+ try {
+ $phoneNumberProto = $phoneUtil->parse($phoneNumber, $address->getCountry()->getIsoalpha2());
+
+ $phoneNationalNumber = $phoneNumberProto->getNationalNumber();
+ $phoneCountryCode = $phoneNumberProto->getCountryCode();
+ } catch (NumberParseException $e) {
+ Tlog::getInstance()->error('Failed to parse phone number "'.$phoneNumber.'", error is : '.$e->getMessage());
+ }
+
+ $billingXml = new \SimpleXMLElement('');
+ $addressXml = $billingXml->addChild('Address');
+
+ $addressXml->addChild('FirstName', $address->getFirstname());
+ $addressXml->addChild('LastName', $address->getLastname());
+ $addressXml->addChild('Address1', $address->getAddress1());
+ $addressXml->addChild('ZipCode', $address->getZipcode());
+ $addressXml->addChild('City', $address->getCity());
+ $addressXml->addChild('CountryCode', $address->getCountry()->getIsocode());
+ $addressXml->addChild('CountryCodeMobilePhone', '+'.$phoneCountryCode);
+ $addressXml->addChild('MobilePhone', $phoneNationalNumber);
+
+ return str_replace(["\n", "\r"], '', $billingXml->asXML());
+ }
+
+ /**
+ * @return array|bool|string|string[]
+ */
+ protected function getShoppingCart(Order $order)
+ {
+ $quantity = 0;
+ $shoppingCartXml = new \SimpleXMLElement('');
+
+ foreach ($order->getOrderProducts() as $product) {
+ $quantity += $product->getQuantity();
+ }
+
+ $total = $shoppingCartXml->addChild('total');
+ $total->addChild('totalQuantity', $quantity);
+
+ return str_replace(["\n", "\r"], '', $shoppingCartXml->asXML());
+ }
+
+ /**
+ * @return bool true to allow usage of this payment module, false otherwise
+ */
+ public function isValidPayment(): bool
+ {
+ $valid = false;
+
+ $mode = self::getConfigValue('mode', false);
+
+ // If we're in test mode, do not display Paybox on the front office, except for allowed IP addresses.
+ if ('TEST' === $mode) {
+ $raw_ips = explode("\n", self::getConfigValue('allowed_ip_list', ''));
+
+ $allowed_client_ips = [];
+
+ foreach ($raw_ips as $ip) {
+ $allowed_client_ips[] = trim($ip);
+ }
+
+ $client_ip = $this->getRequest()->getClientIp();
+
+ $valid = \in_array($client_ip, $allowed_client_ips);
+ } elseif ('PRODUCTION' === $mode) {
+ $valid = true;
+ }
+
+ if ($valid) {
+ // Check if total order amount is in the module's limits
+ $valid = $this->checkMinMaxAmount();
+ }
+
+ return $valid;
+ }
+
+ /**
+ * Check if total order amount is in the module's limits.
+ *
+ * @return bool true if the current order total is within the min and max limits
+ */
+ protected function checkMinMaxAmount(): bool
+ {
+ // Check if total order amount is in the module's limits
+ $order_total = $this->getCurrentOrderTotalAmount();
+
+ $min_amount = self::getConfigValue('minimum_amount', 0);
+ $max_amount = self::getConfigValue('maximum_amount', 0);
+
+ return $order_total > 0
+ && ($min_amount <= 0 || $order_total >= $min_amount)
+ && ($max_amount <= 0 || $order_total <= $max_amount);
+ }
+
+ /**
+ * Get the numeric ISO 4217 code of a currency.
+ *
+ * @param string $textCurrencyCode currency textual code, like EUR or USD
+ *
+ * @return string the algorithm
+ *
+ * @throw \RuntimeException if no algorithm was found.
+ */
+ protected function getCurrencyIso4217NumericCode($textCurrencyCode)
+ {
+ $currencies = null;
+
+ $localIso417data = __DIR__.DS.'Config'.DS.'iso4217.xml';
+
+ $currencyXmlDataUrl = 'http://www.currency-iso.org/dam/downloads/lists/list_one.xml';
+
+ $xmlData = @file_get_contents($currencyXmlDataUrl);
+
+ try {
+ $currencies = new \SimpleXMLElement($xmlData);
+
+ // Update the local currencies copy.
+ @file_put_contents($localIso417data, $xmlData);
+ } catch (\Exception $ex) {
+ Tlog::getInstance()->warning("Failed to get currency XML data from $currencyXmlDataUrl: ".$ex->getMessage());
+ try {
+ $currencies = new \SimpleXMLElement(@file_get_contents($localIso417data));
+ } catch (\Exception $ex) {
+ Tlog::getInstance()->warning("Failed to get currency XML data from local copy $localIso417data: ".$ex->getMessage());
+ }
+ }
+
+ if (null !== $currencies) {
+ foreach ($currencies->CcyTbl->CcyNtry as $country) {
+ if ($country->Ccy == $textCurrencyCode) {
+ return (string) $country->CcyNbr;
+ }
+ }
+ }
+
+ // Last chance
+ switch ($textCurrencyCode) {
+ case 'USD':
+ return 840;
+ case 'GBP':
+ return 826;
+ break;
+ case 'EUR':
+ return 978;
+ break;
+ }
+
+ throw new \RuntimeException(
+ Translator::getInstance()->trans(
+ 'Failed to get ISO 4217 data for currency %curr, payment is not possible.',
+ ['%curr' => $textCurrencyCode]
+ )
+ );
+ }
+
+ /**
+ * Find a suitable hashing algorithm.
+ *
+ * @return string the algorithm
+ *
+ * @throw \RuntimeException if no algorithm was found.
+ */
+ protected function getHashAlgorithm(): string
+ {
+ // Possible hashes
+ $hashes = [
+ 'sha512',
+ 'sha256',
+ 'sha384',
+ 'ripemd160',
+ 'sha224',
+ 'mdc2',
+ ];
+
+ $hashEnabled = hash_algos();
+
+ foreach ($hashes as $hash) {
+ if (\in_array($hash, $hashEnabled)) {
+ return strtoupper($hash);
+ }
+ }
+
+ throw new \RuntimeException(
+ Translator::getInstance()->trans(
+ 'Failed to find a suitable hash algorithm. Please check your PHP configuration.'
+ )
+ );
+ }
+}
diff --git a/local/modules/Paybox/README.md b/local/modules/Paybox/README.md
index 2d39cba4..39d976cc 100644
--- a/local/modules/Paybox/README.md
+++ b/local/modules/Paybox/README.md
@@ -3,6 +3,8 @@
Ce module vous permet de proposer à vos clients le système de paiement Paybox.
+> Compatible 3Dsv2
+
### Installation
> Ce module requiert Thelia 2.1 beta1 au minimum
@@ -29,6 +31,8 @@ This module offers to your customers the Paybox payment system.
> This module requires Thelia 2.1 beta1 or newer
+> Compatible 3Dsv2
+
To install the Paybox module, uncompress the archive in the `/local/modules` directory. Be sure that the name of the module's directory is `Paybox` (and not `Paybox-master`, for exemple).
### Usage
diff --git a/local/modules/Paybox/_notes/dwsync.xml b/local/modules/Paybox/_notes/dwsync.xml
deleted file mode 100644
index eb1257f4..00000000
--- a/local/modules/Paybox/_notes/dwsync.xml
+++ /dev/null
@@ -1,7 +0,0 @@
-
-
-
-
-
-
-
\ No newline at end of file
diff --git a/local/modules/Paybox/composer.json b/local/modules/Paybox/composer.json
index 10ac51ca..f5a360a5 100644
--- a/local/modules/Paybox/composer.json
+++ b/local/modules/Paybox/composer.json
@@ -4,9 +4,18 @@
"license": "LGPL-3.0+",
"type": "thelia-module",
"require": {
- "thelia/installer": "~1.0"
+ "thelia/installer": "~1.0",
+ "giggsey/libphonenumber-for-php": "^8.13"
+ },
+ "suggest": {
+ "thelia/paybox3x-module": "This module offers to your customers the Paybox 3x payment system"
},
"extra": {
"installer-name": "Paybox"
+ },
+ "config": {
+ "allow-plugins": {
+ "thelia/installer": true
+ }
}
-}
\ No newline at end of file
+}
diff --git a/local/modules/Paybox/documentation/_notes/dwsync.xml b/local/modules/Paybox/documentation/_notes/dwsync.xml
deleted file mode 100644
index f4db4b84..00000000
--- a/local/modules/Paybox/documentation/_notes/dwsync.xml
+++ /dev/null
@@ -1,5 +0,0 @@
-
-
-
-
-
\ No newline at end of file
diff --git a/local/modules/Paybox/images/_notes/dwsync.xml b/local/modules/Paybox/images/_notes/dwsync.xml
deleted file mode 100644
index 294f2fcd..00000000
--- a/local/modules/Paybox/images/_notes/dwsync.xml
+++ /dev/null
@@ -1,4 +0,0 @@
-
-
-
-
\ No newline at end of file
diff --git a/local/modules/Paybox/images/paybox-logo.png b/local/modules/Paybox/images/paybox-logo.png
index 47b9cb64..320f7cd1 100644
Binary files a/local/modules/Paybox/images/paybox-logo.png and b/local/modules/Paybox/images/paybox-logo.png differ