osCommerce France : Accueil Forum Portail osCommerce France Réponses aux questions Foire aux contributions

Bienvenue invité ( Connexion | Inscription )

 
Reply to this topicStart new topic
> Incohérence adresse, TVA, prix affiché, prix payé (si, si), Décryptage de logs pour contremesures (édité)
chti_poupon
posté 16 Mar 2014, 11:21
Message #1


Ceinture noire OSC
Icône de groupe

Groupe : TechDev
Messages : 2757
Inscrit : 9-September 08
Lieu : Douai
Membre no 22915



Bonjour
Mes réglages de session:
Force cookies use & Prevent spiders à true, le reste à false (sessions en base de données)

la commande reçue:
Client en France, sans adresse expédition, ni facturation
TVA non comptée
Total bon (sans TVA non plus)
Paiement 3DSecure accepté et, depuis, réellement crédité sur mon compte, mais pour un montant encore inférieur au total (sans TVA) affiché.
La banque donne un paiement à l'heure marquée dans les logs ci-dessous MAIS les courriels me sont parvenus le lendemain à 14:59 !!?

Je reste sec sur l'interprétation des logs (cf extraits infra).
(Le template cité est une centralisation des fichiers css standards)
Merci de vos commentaires.
Chti poupon
PS
je suis en MS2.2 multiboutiques
PJ: extrait des logs concernés - parties "louches"
Citation
www.mon_site.com (IP"client") - - [xx/ABC/2014:22:21:52 +0100] "GET /catalog/mein_sony/pixel_trans.gif HTTP/1.1" 200 43 "http://api.orangemail.orange.fr/"
www.mon_site.com (IP"client") - - [xx/ABC/2014:22:21:52 +0100] "GET /catalog/mein_sony/l_fournis/mon_logo.jpg HTTP/1.1" 404 787 "http://api.orangemail.orange.fr/"
www.mon_site.com (IP"client") - - [xx/ABC/2014:22:22:20 +0100] "GET /catalog/pw.php?action=reg&pass=Q1ZQqNjguA&cuid=(id_"client") HTTP/1.1" 200 6452 "-"
www.mon_site.com (IP"client") - - [xx/ABC/2014:22:22:21 +0100] "GET /catalog/mein_sony/table_background_specials.gif HTTP/1.1" 200 1124 "http://www.mon_site.com/catalog/pw.php?action=reg&pass=Q1ZQqNjguA&cuid=(id_"client")"
www.mon_site.com (IP"client") - - [xx/ABC/2014:22:23:00 +0100] "GET /catalog/categorie1-c-1.html HTTP/1.1" 200 7811 "http://www.mon_site.com/catalog/index.php"

..................
www.mon_site.com (IP"client") - - [xx/ABC/2014:23:02:43 +0100] "POST /catalog/categorie1-categorie2-categorie3-produitA-p-83.html?action=add_product HTTP/1.1" 301 26 "http://www.mon_site.com/catalog/categorie1-categorie2-categorie3-produitA-p-83.html"
www.mon_site.com (IP"client") - - [xx/ABC/2014:23:02:44 +0100] "GET /catalog/categorie1-categorie2-categorie3-produitA-p-83.html HTTP/1.1" 301 10490 "http://www.mon_site.com/catalog/categorie1-categorie2-categorie3-produitA-p-83.html"

.........................
www.mon_site.com (IP"client") - - [xx/ABC/2014:22:14:59 +0100] "GET /templates_osc/templatemonsite/images/languages/french/button_continue.gif HTTP/1.1" 200 762 "http://www.mon_site.com/catalog/create_account.php"
www.mon_site.com (IP"client") - - [xx/ABC/2014:22:19:33 +0100] "POST /catalog/create_account.php HTTP/1.1" 200 11673 "http://www.mon_site.com/catalog/create_account.php"

.....................
www.mon_site.com (IP"client") - - [xx/ABC/2014:23:05:29 +0100] "GET /catalog/mein_sony/pixel_silver.gif HTTP/1.1" 200 35 "http://www.mon_site.com/catalog/checkout_shipping.php"
www.mon_site.com (IP"client") - - [xx/ABC/2014:23:06:21 +0100] "POST /catalog/checkout_shipping.php HTTP/1.1" 302 26 "http://www.mon_site.com/catalog/checkout_shipping.php"


.......................
www.mon_site.com (IP"client") - - [xx/ABC/2014:23:06:23 +0100] "GET /catalog/mein_sony/divers/verified-by-visa.jpg HTTP/1.1" 200 5321 "http://www.mon_site.com/catalog/checkout_payment.php"
www.mon_site.com (IP"client") - - [xx/ABC/2014:23:07:23 +0100] "POST /catalog/checkout_confirmation.php HTTP/1.1" 200 7532 "http://www.mon_site.com/catalog/checkout_payment.php"


......................
www.mon_site.com (IP"client") - - [xx/ABC/2014:23:07:25 +0100] "GET /templates_osc/templatemonsite/images/languages/french/button_confirm_order.gif HTTP/1.1" 200 968 "http://www.mon_site.com/catalog/checkout_confirmation.php"

Là la banque a enregistré le paiement
et le lendemain :
Citation
www.mon_site.com (IP"client") - - [xy/ABC/2014:14:33:52 +0100] "GET /catalog/pw.php?action=reg&pass=Q1ZQqNjguA&cuid=(id_"client") HTTP/1.1" 200 6477 "-"
www.mon_site.com (IP"client") - - [xy/ABC/2014:14:33:54 +0100] "GET /catalog/mein_sony/table_background_specials.gif HTTP/1.1" 200 1124 "http://www.mon_site.com/catalog/pw.php?action=reg&pass=Q1ZQqNjguA&cuid=(id_"client")"
www.mon_site.com (IP"client") - - [xy/ABC/2014:14:34:35 +0100] "GET /catalog/mein_sony/table_background_cart.gif HTTP/1.1" 200 1472 "http://www.mon_site.com/catalog/shopping_cart.php"
www.mon_site.com (IP"client") - - [xy/ABC/2014:14:34:35 +0100] "GET /templates_osc/templatemonsite/images/languages/french/button_checkout.gif HTTP/1.1" 200 747 "http://www.mon_site.com/catalog/shopping_cart.php"
www.mon_site.com (IP"client") - - [xy/ABC/2014:14:34:35 +0100] "GET /templates_osc/templatemonsite/images/languages/french/button_update_cart.gif HTTP/1.1" 200 818 "http://www.mon_site.com/catalog/shopping_cart.php"
www.mon_site.com (IP"client") - - [xy/ABC/2014:14:34:35 +0100] "GET /templates_osc/templatemonsite/images/languages/french/button_continue_shopping.gif HTTP/1.1" 200 968 "http://www.mon_site.com/catalog/shopping_cart.php"
www.mon_site.com (IP"client") - - [xy/ABC/2014:14:35:21 +0100] "GET /catalog/par-sachet-categorie4-c-1_4_22_195_76.html HTTP/1.1" 301 9065 "http://www.mon_site.com/catalog/categorie1-categorie2-categorie3-c-1_4_22_195.html"
www.mon_site.com (IP"client") - - [xy/ABC/2014:14:35:22 +0100] "GET /catalog/categorie1-categorie2-categorie3-categorie4-c-1_4_22_195_76.html HTTP/1.1" 200 9061 "http://www.mon_site.com/catalog/categorie1-categorie2-categorie3-c-1_4_22_195.html"
www.mon_site.com (IP"client") - - [xy/ABC/2014:14:35:46 +0100] "POST /catalog/par-sachet-categorie4-c-1_4_22_195_76.html?products_id=84&action=buy_now&sort=3a HTTP/1.1" 301 26 "http://www.mon_site.com/catalog/categorie1-categorie2-categorie3-categorie4-c-1_4_22_195_76.html"
www.mon_site.com (IP"client") - - [xy/ABC/2014:14:35:46 +0100] "GET /catalog/categorie4-c-1_4_22_195_76.html?sort=3a HTTP/1.1" 301 9177 "http://www.mon_site.com/catalog/categorie1-categorie2-categorie3-categorie4-c-1_4_22_195_76.html"
www.mon_site.com (IP"client") - - [xy/ABC/2014:14:35:47 +0100] "GET /catalog/categorie1-categorie2-categorie3-categorie4-c-1_4_22_195_76.html?sort=3a HTTP/1.1" 200 9178 "http://www.mon_site.com/catalog/categorie1-categorie2-categorie3-categorie4-c-1_4_22_195_76.html"
www.mon_site.com (IP"client") - - [xy/ABC/2014:14:36:11 +0100] "GET /catalog/categorie1-categorie2-categorie3-categorie4-produitB-p-84.html HTTP/1.1" 301 10504 "http://www.mon_site.com/catalog/categorie1-categorie2-categorie3-categorie4-c-1_4_22_195_76.html?sort=3a"
www.mon_site.com (IP"client") - - [xy/ABC/2014:14:36:12 +0100] "GET /catalog/categorie1-categorie2-categorie3-categorie4-produitB-p-84.html HTTP/1.1" 200 10506 "http://www.mon_site.com/catalog/categorie1-categorie2-categorie3-categorie4-c-1_4_22_195_76.html?sort=3a"
www.mon_site.com (IP"client") - - [xy/ABC/2014:14:36:17 +0100] "GET /catalog/checkout_shipping.php HTTP/1.1" 302 26 "http://www.mon_site.com/catalog/categorie1-categorie2-categorie3-categorie4-produitB-p-84.html"
www.mon_site.com (IP"client") - - [xy/ABC/2014:14:36:17 +0100] "GET /catalog/login.php HTTP/1.1" 200 6802 "http://www.mon_site.com/catalog/categorie1-categorie2-categorie3-categorie4-produitB-p-84.html"
www.mon_site.com (IP"client") - - [xy/ABC/2014:14:36:18 +0100] "GET /catalog/mein_sony/table_background_login.gif HTTP/1.1" 200 1381 "http://www.mon_site.com/catalog/login.php"
www.mon_site.com (IP"client") - - [xy/ABC/2014:14:36:48 +0100] "GET /catalog/account.php HTTP/1.1" 302 26 "http://www.mon_site.com/catalog/login.php"
www.mon_site.com (IP"client") - - [xy/ABC/2014:14:36:57 +0100] "POST /catalog/login.php?action=process HTTP/1.1" 302 26 "http://www.mon_site.com/catalog/login.php"
www.mon_site.com (IP"client") - - [xy/ABC/2014:14:36:57 +0100] "GET /catalog/account.php HTTP/1.1" 200 7351 "http://www.mon_site.com/catalog/login.php"
www.mon_site.com (IP"client") - - [xy/ABC/2014:14:36:59 +0100] "GET /catalog/mein_sony/account_personal.gif HTTP/1.1" 200 2534 "http://www.mon_site.com/catalog/account.php"
www.mon_site.com (IP"client") - - [xy/ABC/2014:14:36:59 +0100] "GET /catalog/mein_sony/account_orders.gif HTTP/1.1" 200 2381 "http://www.mon_site.com/catalog/account.php"
www.mon_site.com (IP"client") - - [xy/ABC/2014:14:36:59 +0100] "GET /catalog/mein_sony/account_rewards.gif HTTP/1.1" 404 787 "http://www.mon_site.com/catalog/account.php"
www.mon_site.com (IP"client") - - [xy/ABC/2014:14:36:59 +0100] "GET /catalog/images/arrow_south_east.gif HTTP/1.1" 404 787 "http://www.mon_site.com/catalog/account.php"
www.mon_site.com (IP"client") - - [xy/ABC/2014:14:36:59 +0100] "GET /catalog/mein_sony/account_notifications.gif HTTP/1.1" 200 1701 "http://www.mon_site.com/catalog/account.php"
www.mon_site.com (IP"client") - - [xy/ABC/2014:14:38:08 +0100] "POST /catalog/categorie2-categorie5-c-1_4_204.html?products_id=414&action=buy_now&sort=3a HTTP/1.1" 301 26 "http://www.mon_site.com/catalog/categorie1-categorie2-categorie5-c-1_4_204.html?sort=3a"
www.mon_site.com (IP"client") - - [xy/ABC/2014:14:38:09 +0100] "GET /catalog/categorie2-categorie5-c-1_4_204.html?sort=3a HTTP/1.1" 301 9315 "http://www.mon_site.com/catalog/categorie1-categorie2-categorie5-c-1_4_204.html?sort=3a"
www.mon_site.com (IP"client") - - [xy/ABC/2014:14:38:10 +0100] "GET /catalog/categorie1-categorie2-categorie5-c-1_4_204.html?sort=3a HTTP/1.1" 200 9317 "http://www.mon_site.com/catalog/categorie1-categorie2-categorie5-c-1_4_204.html?sort=3a"
www.mon_site.com (IP"client") - - [xy/ABC/2014:14:39:18 +0100] "POST /catalog/shopping_cart.php?action=update_product HTTP/1.1" 302 26 "http://www.mon_site.com/catalog/shopping_cart.php"
www.mon_site.com (IP"client") - - [xy/ABC/2014:14:39:18 +0100] "GET /catalog/shopping_cart.php HTTP/1.1" 200 7168 "http://www.mon_site.com/catalog/shopping_cart.php"
www.mon_site.com (IP"client") - - [xy/ABC/2014:14:49:02 +0100] "POST /catalog/login.php?action=process HTTP/1.1" 302 26 "http://www.mon_site.com/catalog/login.php"
www.mon_site.com (IP"client") - - [xy/ABC/2014:14:49:02 +0100] "GET /catalog/index.php HTTP/1.1" 200 9257 "http://www.mon_site.com/catalog/login.php"
www.mon_site.com (IP"client") - - [xy/ABC/2014:14:52:43 +0100] "GET /catalog/checkout_success.php HTTP/1.1" 200 6719 "-"
www.mon_site.com (IP"client") - - [xy/ABC/2014:14:52:44 +0100] "GET /catalog/mein_sony/table_background_man_on_board.gif HTTP/1.1" 200 4301 "http://www.mon_site.com/catalog/checkout_success.php"
www.mon_site.com (IP"client") - - [xy/ABC/2014:14:52:44 +0100] "GET /templates_osc/templatemonsite/images/languages/french/button_print_order.gif HTTP/1.1" 200 1519 "http://www.mon_site.com/catalog/checkout_success.php"
www.mon_site.com (IP"client") - - [xy/ABC/2014:14:52:44 +0100] "GET /templates_osc/templatemonsite/images/icons/cart.gif HTTP/1.1" 200 234 "http://www.mon_site.com/catalog/checkout_success.php"

Là, je venais de recevoir l'avis de paiement et le courriel de commande

Ce message a été modifié par chti_poupon - 16 Mar 2014, 17:42.
Raison de l'édition : complément logs du lendemain
Go to the top of the page
 
zevacu
posté 17 Mar 2014, 09:34
Message #2


Ceinture jaune OSC
Icône de groupe

Groupe : Membres
Messages : 77
Inscrit : 8-November 05
Lieu : zevaco
Membre no 7753



On dirait quelqu'un qui teste des codes piratés, y compris les codes 3D-secure (plus courant qu'on ne le croit), ce qui expliquerait l'absence d'adresse d'expédition, mais pas l'erreur de TVA.


--------------------
Zevacu

OSC 2.334, Ultimate SEO 5 Pro, Headers Tags SEO V.3.3.2 (1), Atos 3.2
Go to the top of the page
 
Gnidhal
posté 25 Mar 2014, 15:30
Message #3


5eme dan OSC
Icône de groupe

Groupe : Administrateur
Messages : 9221
Inscrit : 4-March 03
Lieu : Pau
Membre no 927



B'jour wink.gif
L'absence de TVA s'explique : pas d'adresse de livraison = pas de TVA applicable. La TVA est toujours appliquée selon la destination de livraison.
Pour le reste, la lecture des logs a toujours été pour moi une corvée abominable.
Pour suivre un client, il est bon de supprimer tout ce qui n'est pas utile sinon on s'y perd, les images par exemple.
Dans la logique, un client suit toujours le même chemin et celui du tien n'a pas l'air plus louche que ça :
shopping_cart > create_account (si pas déjà loggué)
puis checkout...
_shipping
_paiement
_confirmation
envoi vers site de paiement avec des données en POST
retour vers un script spécifique ou validation silencieuse par la banque (url de validation)
_process si le script de validation de valide pas
_success pour dire que tout s'est bien passé.
C'est dans create_account que le client créé son adresse dans le carnet d'adresses
cette adresse est reprise dans _shipping, cela déterminera la TVA
dans _paiement il choisi son mode de paiement (chèque, CB, Paypal...) et dans _confirmation on a un aperçu du total et de l'adresse de livraison.

Donc tes logs semblent définir que ton client a ouvert une autre session avec un autre navigateur en parallèle (intentionnellement ou par erreur) et donc dégagé le total qui devait partir dans _confirmation vers la banque
Il me semble qu'il existe des lignes dans ce _confirmation qui interdit cela :
Code
// if the customer is not logged on, redirect them to the login page
  if (!tep_session_is_registered('customer_id')) {
    $navigation->set_snapshot(array('mode' => 'SSL', 'page' => FILENAME_CHECKOUT_PAYMENT));
    tep_redirect(tep_href_link(FILENAME_LOGIN, '', 'SSL'));
  }

// if there is nothing in the customers cart, redirect them to the shopping cart page
  if ($cart->count_contents() < 1) {
    tep_redirect(tep_href_link(FILENAME_SHOPPING_CART));
  }

// avoid hack attempts during the checkout procedure by checking the internal cartID
  if (isset($cart->cartID) && tep_session_is_registered('cartID')) {
    if ($cart->cartID != $cartID) {
      tep_redirect(tep_href_link(FILENAME_CHECKOUT_SHIPPING, '', 'SSL'));
    }
  }

// if no shipping method has been selected, redirect the customer to the shipping method selection page
  if (!tep_session_is_registered('shipping')) {
    tep_redirect(tep_href_link(FILENAME_CHECKOUT_SHIPPING, '', 'SSL'));
  }
(code d'une MS2 basique)
Si le panier a changé, on retourne à la livraison,
Si l'id de shipping est manquante on retourne à livraison...
Bref, si ya un loup, on retourne au début du fil de traitement dans _shipping pour recalculer la TVA et la suite en reprenant la dernière valeur dans shopping_cart.

Vire tous les parasites de tes logs et ne garde que l'essentiel du fil de fonctionnement dans l'ordre. Ce que je vois ici
Code
www.mon_site.com (IP"client") - - [xy/ABC/2014:14:49:02 +0100] "GET /catalog/index.php HTTP/1.1" 200 9257 "http://www.mon_site.com/catalog/login.php"
www.mon_site.com (IP"client") - - [xy/ABC/2014:14:52:43 +0100] "GET /catalog/checkout_success.php HTTP/1.1" 200 6719 "-"

On ne passe pas de login à success directement
donc quand le client est en banque, il ouvre une autre session en parallèle (login) et parallèlement success
Or success ne fait rien que d'afficher un résultat après process : où est l'appel à process ?
Regarde si tu n'as pas un id de session qui traine dans tes suivis de logs car 2 sessions parallèles ne peuvent se marcher dessus même avec un même compte client.

Il n'a fait que mettre le boxon dans le paiement et dans les commandes.
Je ne pense pas qu'il faille prêter trop d'attention à tout ça : il n'y a pas que faille qui faille! Vaille que vaille!


--------------------
Tout d'abord : - Ni Hotline ni Service Après Vente, ces forums sont un lieu d'échange. BIEN POSER SA QUESTION (généralités)
Les "Informations Importantes" que vous devez ABSOLUMENT avoir lues :
Règlement, Bien poser sa question dans ces forums et Bien utiliser les Forums.
Les raccourcis pour gagner du temps : la FAQ, les PDF de la Doc (MS2-fr): PDF-V1 et PDF-V2, le moteur de Recherche sur les forums , la Liste des Contributions de Corbin.

----------------------------- Quelques sites de référence ---------------------------
PHP: Le site du Zéro et PHP Débutant avec la DOC en français -- HTML: Self HTML - WebProgrammation -- CSS: OpenWeb - AlsaCréations - CSS/Edge -- Autres ressources: - XajaX - highslide js
Les bons outils : EasyPHP - WAMP-5 - - Notepad++ - Firefox et son extension WebDeveloper
Le gène idéal c'est le gène original. Le génie des halles est un Génie des Alpages qui tente d'être à la page. (Merci f'murrr pour les cours de philosophie de chien)
Go to the top of the page
 
chti_poupon
posté 26 Mar 2014, 13:03
Message #4


Ceinture noire OSC
Icône de groupe

Groupe : TechDev
Messages : 2757
Inscrit : 9-September 08
Lieu : Douai
Membre no 22915



Bonjour
@Gnidhal
Merci de ta réponse.
Les extraits de logs que j'ai mis sont épurés sur la base du même IP, et dans l'ordre. J'ai viré la partie création du panier, standard.
IL y a eu effectivement double connection via le même IP et copie d'osCid de l'un à l'autre.
La suppression des adresses de livraison et de facturation déclenche, en effet, la suppression de la TVA. et le changement du total à payer de mon_site à celui de la banque (cmcic) implique la modification du panier après le paiement... et la fin du processus plus de 12 heures plus tard.
J'ai tenté de modifier normalement les adresses, mais les sécurités fonctionnent.
Au final, je me suis aperçu que create_account était modifié par une contrib (Mail Validation) dont le dernier bugfix n'avait pas été pris en compte. Et cela explique la possibilité des manoeuvres faites. Ce bugfix est en effet, dans create_account_success:
Code
//add this
if (EMAIL_VALIDATION=='true'){
//before tep_session_unregister('customer_id'); tep_session_unregister('customer_default_address_id');
tep_session_unregister('customer_first_name');
tep_session_unregister('customer_country_id');
tep_session_unregister('customer_zone_id');
tep_session_unregister('comments');
//and add
}
//after

En son absence il paraît possible de "corriger" le contenu de la session en externe avant de revenir.
MORALITE : toujours "suivre" les contribs utilisées !
Qu'en penses-tu ?
Chti poupon
PS j'ai mis à true tous les réglages de session par précaution
Go to the top of the page
 

Reply to this topicStart new topic
1 utilisateur(s) sur ce sujet (1 invité(s) et 0 utilisateur(s) anonyme(s))
0 membre(s) :

 



RSS Version bas débit Nous sommes le : 28th March 2024 - 22:13
Ce site est déclaré auprès de la commision Nationale
de l'Informatique et des Libertés (déclaration n°: 1043896)