longstockings Posted November 12, 2009 Posted November 12, 2009 Hi I've downloaded, installed and configured the HSBC E-Secure payment module and have done my best to follow the poor provided documentation from HSBC. Currently every time I try to checkout I am redirected to hsbc_return.php with the error message "Hacking Attempt". I have uploaded the orderhash files etc to my cgi-bin and have installed the library files onto my server except for libstdc++-libc6.2-2.so which my web host was not happy about installing due to possible server stability issues. My web host (Wiredtree) said "These libraries are already installed: [root@host ~]# rpm -qa | grep stdc libstdc++-4.1.2-46.el5_4.1 libstdc++-devel-4.1.2-46.el5_4.1 I'm sorry it's taken a while to respond. I spoke with some other admins here, and we are in agreement with my initial feeling that it is very dangerous to copy libraries around like this. They should be built by compilers in a very measured careful way and trying to copy build libraries around from uncertain architecture can have very disastrous results. I recommend you contact the developer of this module to find out what could be going on to make sure you don't compromise system stability in hopes of getting his module to work. " I have spoken to HSBC's tech support who are pretty useless and they didn't mention that not having this would be a problem and after checking their server logs informed me that the timestamp was incorrect. They said "The value of TimeStamp should be positive 13 digits. You have to check the program that is generating the timestamp and then amend it accordingly. Unfortunately, we would ot be able to amend the code as it is beyond our support boundaries. The TimeStamp value we have recieved yesterday for a transaction was "1.257867669E+12". As it contains a (.), (E) and (+). The timestamp should be in numeric not in exponential form." This may as well be written in Hebrew as I don't understand what I should be changing in order for the timestamp to be generated correctly. The code responsible for generating the timestamp is found in /includes/modules/payment/hsbc.php and looks like this //POST time $time=time(); //Change the 0 if your server is located at a different GMT time $time=($time+(0*3600)); $time=$time*1000; My server is in Chicago but does have the time set to GMT. It runs CentOS with Litespeed. Any help with getting this working would be much appreciated. I've scoured the Internet for information and it would appear that lots of people had problems installing this module and many have simply given up. Thanks
web-project Posted November 14, 2009 Posted November 14, 2009 My server is in Chicago but does have the time set to GMT. It runs CentOS with Litespeed. simply add the time difference to get the GMT time. Please read this line: Do you want to find all the answers to your questions? click here. As for contribution database it's located here! 8 people out of 10 don't bother to read installation manuals. I can recommend: if you can't read the installation manual, don't bother to install any contribution yourself. Before installing contribution or editing/updating/deleting any files, do the full backup, it will save to you & everyone here on the forum time to fix your issues. Any issues with oscommerce, I am here to help you.
germ Posted November 14, 2009 Posted November 14, 2009 I took the code you posted and put it on a test page I have and I get this: 1258219942000 As a sample output. :huh: If I suggest you edit any file(s) make a backup first - I'm not perfect and neither are you. "Given enough impetus a parallelogramatically shaped projectile can egress a circular orifice." - Me - "Headers already sent" - The definitive help "Cannot redeclare ..." - How to find/fix it SSL Implementation Help Like this post? "Like" it again over there >
germ Posted November 14, 2009 Posted November 14, 2009 This might work. Change this code: //POST time $time=time(); //Change the 0 if your server is located at a different GMT time $time=($time+(0*3600)); $time=$time*1000; to //POST time $time=time(); //Change the 0 if your server is located at a different GMT time $time=($time+(0*3600)); $time=$time*1000; $time_string = sprintf("%13.0f",(float)$time); Then a few lines farther down in the same file: 'TimeStamp'=>$time, Would need changed to: 'TimeStamp'=>$time_string, As always it's an excellent idea to backup a file before making edits. If I suggest you edit any file(s) make a backup first - I'm not perfect and neither are you. "Given enough impetus a parallelogramatically shaped projectile can egress a circular orifice." - Me - "Headers already sent" - The definitive help "Cannot redeclare ..." - How to find/fix it SSL Implementation Help Like this post? "Like" it again over there >
longstockings Posted November 15, 2009 Author Posted November 15, 2009 This might work. Change this code: //POST time $time=time(); //Change the 0 if your server is located at a different GMT time $time=($time+(0*3600)); $time=$time*1000; to //POST time $time=time(); //Change the 0 if your server is located at a different GMT time $time=($time+(0*3600)); $time=$time*1000; $time_string = sprintf("%13.0f",(float)$time); Then a few lines farther down in the same file: 'TimeStamp'=>$time, Would need changed to: 'TimeStamp'=>$time_string, As always it's an excellent idea to backup a file before making edits. Thanks for this and everyone else's advice. I'll give it a go and see if this works. Richard
longstockings Posted November 19, 2009 Author Posted November 19, 2009 Thanks for this and everyone else's advice. I'll give it a go and see if this works. Richard Installed the code above but now 16 digits are being passed to HSBC. I'll make some adjustments and see if I can't get this sorted once and for all.
germ Posted November 19, 2009 Posted November 19, 2009 Installed the code above but now 16 digits are being passed to HSBC. I'll make some adjustments and see if I can't get this sorted once and for all. That's bizarre. :blink: I tested it and it worked on my site (the 13 digit part). If you need help please post an example of the current output and I'll see what I can do. At this point (hopefully) it would be just a matter of string manipulation. If I suggest you edit any file(s) make a backup first - I'm not perfect and neither are you. "Given enough impetus a parallelogramatically shaped projectile can egress a circular orifice." - Me - "Headers already sent" - The definitive help "Cannot redeclare ..." - How to find/fix it SSL Implementation Help Like this post? "Like" it again over there >
Recommended Posts
Archived
This topic is now archived and is closed to further replies.