Future store updates planned (backend)

Latest Atari related news.
User avatar
exxos
Site Admin
Site Admin
Posts: 7639
Joined: Wed Aug 16, 2017 11:19 pm
Location: UK
Contact:

Re: Future store updates planned (backend)

Post by exxos » Wed Aug 28, 2019 9:19 pm

Sidestepped again back to payaservices. I got a reply form tech support about the issue I had and now its solved.. and...

pc.png
pc.png (17.39 KiB) Viewed 603 times


I'm going to finish the payaservices checkout, at least I will then have fall-back plan if sage is going to drag on for a bit.
4MB STFM 1.44 FD- VELOCE+ 020 STE - 4MB STE 32MHz - STFM 16MHz - STM - MEGA ST - Falcon 030 CT60 - Atari 2600 - Atari 7800 - Gigafile - SD Floppy Emulator - PeST - HxC - CosmosEx - Ultrasatan - various clutter

https://www.exxoshost.co.uk/atari/ All my hardware guides - mods - games - STOS
https://www.exxoshost.co.uk/atari/last/storenew/ - All my hardware mods for sale - Please help support by making a purchase.

User avatar
exxos
Site Admin
Site Admin
Posts: 7639
Joined: Wed Aug 16, 2017 11:19 pm
Location: UK
Contact:

Re: Future store updates planned (backend)

Post by exxos » Thu Aug 29, 2019 10:28 am

More chaos. Overall, it seems payment systems don't do what I want exactly (or at least how things are running now on my live store). I have to moved to more complicated systems which require PCI compliance..

to which I got back..
If you're using shared hosting, I don't believe it's possible to get PCI compliance, as the PCI compliance requires isolation of data, and as you can imagine, with other sites outside of your control being on the same server, then there is always the possibility that this data may be breached from other sites.
I just got a email from Worldpay saying I am getting billed £4.99 a month, WTF ? Had to email Sage and ask WTF is going on. As I would be paying fees per month with Sage, plus 1.5% transaction fess, plus Worldpay fees...

I just seem to be going around in ever increasing circles :( This is all getting very tiresome :(
4MB STFM 1.44 FD- VELOCE+ 020 STE - 4MB STE 32MHz - STFM 16MHz - STM - MEGA ST - Falcon 030 CT60 - Atari 2600 - Atari 7800 - Gigafile - SD Floppy Emulator - PeST - HxC - CosmosEx - Ultrasatan - various clutter

https://www.exxoshost.co.uk/atari/ All my hardware guides - mods - games - STOS
https://www.exxoshost.co.uk/atari/last/storenew/ - All my hardware mods for sale - Please help support by making a purchase.

User avatar
exxos
Site Admin
Site Admin
Posts: 7639
Joined: Wed Aug 16, 2017 11:19 pm
Location: UK
Contact:

Re: Future store updates planned (backend)

Post by exxos » Thu Aug 29, 2019 5:07 pm

Rang up Sage earlier. After a hour, basically they don't know what the problem is either. They were supposed to be ringing me back, but that was 3 hours ago now :roll:

I may ring them up again on Monday, but when their own tech support doesn't know what the problem is with their own system, how am I supposed to solve it ?! Apparently they never had the issue I am having , figures :roll: .
4MB STFM 1.44 FD- VELOCE+ 020 STE - 4MB STE 32MHz - STFM 16MHz - STM - MEGA ST - Falcon 030 CT60 - Atari 2600 - Atari 7800 - Gigafile - SD Floppy Emulator - PeST - HxC - CosmosEx - Ultrasatan - various clutter

https://www.exxoshost.co.uk/atari/ All my hardware guides - mods - games - STOS
https://www.exxoshost.co.uk/atari/last/storenew/ - All my hardware mods for sale - Please help support by making a purchase.

User avatar
exxos
Site Admin
Site Admin
Posts: 7639
Joined: Wed Aug 16, 2017 11:19 pm
Location: UK
Contact:

Re: Future store updates planned (backend)

Post by exxos » Thu Aug 29, 2019 10:21 pm

No call from Sage :( I mean I have been trying for days to get it working already and I just see nothing wrong. Spent endless hours on google where there seems to be near zero people even asking about sage issues. I managed to tag onto a post on stackoverflow about issues, but I think it's not going to help. I think its pretty conclusive I will just have to give up with thier system :roll:

I have asked payacard if they are supporting 3DS V1 & V2, if yes, I will start coding for their system. If not, then I don't have a PLAN D: :(
4MB STFM 1.44 FD- VELOCE+ 020 STE - 4MB STE 32MHz - STFM 16MHz - STM - MEGA ST - Falcon 030 CT60 - Atari 2600 - Atari 7800 - Gigafile - SD Floppy Emulator - PeST - HxC - CosmosEx - Ultrasatan - various clutter

https://www.exxoshost.co.uk/atari/ All my hardware guides - mods - games - STOS
https://www.exxoshost.co.uk/atari/last/storenew/ - All my hardware mods for sale - Please help support by making a purchase.

User avatar
exxos
Site Admin
Site Admin
Posts: 7639
Joined: Wed Aug 16, 2017 11:19 pm
Location: UK
Contact:

Re: Future store updates planned (backend)

Post by exxos » Fri Aug 30, 2019 1:45 pm

Got a call from Sage accounts, my account is setup <sarcasm> Yippie! </sarcasm>

The first line of code pretty much is...

Code: Select all

  CURLOPT_POSTFIELDS => '{ "vendorName": "sandbox" }',
Which I change to my vendor name..

Code: Select all

  CURLOPT_POSTFIELDS => '{ "vendorName": "exxos" }',
So what happens ?


Uncaught Error: API parameters invalid
- Merchant session key does not have a valid format


I have also tried various combinations of everything I can think of... it just doesn't work :roll:


EDIT:

OK what seems to be very unclear is where it has

Code: Select all

curl_setopt_array($curl, array(
  CURLOPT_URL => "https://pi-test.sagepay.com/api/v1/merchant-session-keys",
  CURLOPT_RETURNTRANSFER => true,
  CURLOPT_CUSTOMREQUEST => "POST",
  CURLOPT_POSTFIELDS => '{ "vendorName": "sandbox" }',
  CURLOPT_HTTPHEADER => array(
    "Authorization: Basic aEpZeHN3N0hMYmo0MGNCOHVkRVM4Q0RSRkxodUo4RzU0TzZyRHBVWHZFNmhZRHJyaWE6bzJpSFNyRnliWU1acG1XT1FNdWhzWFA1MlY0ZkJ0cHVTRHNocktEU1dzQlkxT2lONmh3ZDlLYjEyejRqNVVzNXU=",
    "Cache-Control: no-cache",
    "Content-Type: application/json"
  ),
));
Authorization: Basic, what it fails to explain is that its supposed to be generated from what it says here https://test.sagepay.com/documentation/#authentication

So the code would actually be more like...

Code: Select all

$_SESSION['AUTH'] = base64_encode($integrationKey . ":" . $integrationPassword) ;
The something like

Code: Select all

"Authorization: Basic ".$_SESSION['AUTH'].",

Now to see why php has died running it all... :roll:

EDIT2:

OK its all those quotations messing it up, so now its just...

Code: Select all

"Authorization: Basic $AUTH",
So now I have to go and change all the other code with those lines in now :roll:

EDIT3:

yay a new error :roll:
4020
Information received from an Invalid IP address.
It seems I have to put the IP of my server into Sage to allow payments from my server only.. which I did.. and still same problem :pullhair:
4MB STFM 1.44 FD- VELOCE+ 020 STE - 4MB STE 32MHz - STFM 16MHz - STM - MEGA ST - Falcon 030 CT60 - Atari 2600 - Atari 7800 - Gigafile - SD Floppy Emulator - PeST - HxC - CosmosEx - Ultrasatan - various clutter

https://www.exxoshost.co.uk/atari/ All my hardware guides - mods - games - STOS
https://www.exxoshost.co.uk/atari/last/storenew/ - All my hardware mods for sale - Please help support by making a purchase.

User avatar
exxos
Site Admin
Site Admin
Posts: 7639
Joined: Wed Aug 16, 2017 11:19 pm
Location: UK
Contact:

Re: Future store updates planned (backend)

Post by exxos » Fri Aug 30, 2019 3:15 pm

I found this page

https://stackoverflow.com/questions/176 ... d-ip-addre

Basically..
The issue here was that the IP address of the web server (www.mysite.com), being on a VPS, turned out to not be the same address as the one used when curl requests were made.
So I found this page..

http://nenuno.co.uk/php/get-ip-address-by-curl-in-php/

Where I ran this...

Code: Select all

$url = 'http://php.net/';
$ch = curl_init();
curl_setopt($ch, CURLOPT_URL, $url);
curl_setopt($ch, CURLOPT_FOLLOWLOCATION, TRUE);
curl_setopt($ch, CURLOPT_RETURNTRANSFER, TRUE);       
curl_exec($ch);
$info  = curl_getinfo($ch);  
curl_close($ch);  
echo $info['primary_ip'];
Which gave me a totally different IP address..which I added to Sage.. then does it work now ?
4020
Information received from an Invalid IP address.
Nope :roll:

EDIT:
Now I realised I forgot to charge the $URL :lol: So I changed it , and just got back my server IP , so still no help :roll:
4MB STFM 1.44 FD- VELOCE+ 020 STE - 4MB STE 32MHz - STFM 16MHz - STM - MEGA ST - Falcon 030 CT60 - Atari 2600 - Atari 7800 - Gigafile - SD Floppy Emulator - PeST - HxC - CosmosEx - Ultrasatan - various clutter

https://www.exxoshost.co.uk/atari/ All my hardware guides - mods - games - STOS
https://www.exxoshost.co.uk/atari/last/storenew/ - All my hardware mods for sale - Please help support by making a purchase.

derkom
Posts: 63
Joined: Sun Jul 29, 2018 6:45 pm

Re: Future store updates planned (backend)

Post by derkom » Fri Aug 30, 2019 4:12 pm

Wait, if you're running that php snippet, with your own URL in there, it's certainly going to return the IP of your own site, which may not be the one for outbound stuff.

Look at the Stackoverflow thread you linked, and do what was suggested in the answer there. If you run "curl icanhazip.com" from the shell on your VPS, you'll get back the IP address that's being used for outbound connections.

User avatar
exxos
Site Admin
Site Admin
Posts: 7639
Joined: Wed Aug 16, 2017 11:19 pm
Location: UK
Contact:

Re: Future store updates planned (backend)

Post by exxos » Fri Aug 30, 2019 4:14 pm

derkom wrote:
Fri Aug 30, 2019 4:12 pm
Look at the Stackoverflow thread you linked, and do what was suggested in the answer there. If you run "curl icanhazip.com" from the shell on your VPS, you'll get back the IP address that's being used for outbound connections.
Get the same IP...

1.jpg
1.jpg (5.49 KiB) Viewed 517 times
EDIT:

I even emailed my web host, and they say there is only that 1 IP in use.
4MB STFM 1.44 FD- VELOCE+ 020 STE - 4MB STE 32MHz - STFM 16MHz - STM - MEGA ST - Falcon 030 CT60 - Atari 2600 - Atari 7800 - Gigafile - SD Floppy Emulator - PeST - HxC - CosmosEx - Ultrasatan - various clutter

https://www.exxoshost.co.uk/atari/ All my hardware guides - mods - games - STOS
https://www.exxoshost.co.uk/atari/last/storenew/ - All my hardware mods for sale - Please help support by making a purchase.

derkom
Posts: 63
Joined: Sun Jul 29, 2018 6:45 pm

Re: Future store updates planned (backend)

Post by derkom » Fri Aug 30, 2019 4:18 pm

Got me stumped then. :-?

derkom
Posts: 63
Joined: Sun Jul 29, 2018 6:45 pm

Re: Future store updates planned (backend)

Post by derkom » Fri Aug 30, 2019 4:23 pm

Oh, the Sagepay docs say to zero-pad the IP (for some reason). Have you tried putting 081.004.101.012 in the Sage control panel?

Edit: Subnet mask apparently also needs to be zero-padded (although if you're allowing from only one IP, this'll be 255.255.255.255 regardless).

Post Reply