Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Components Extended [v0.9.3]
#17
(2016-06-20, 21:06:52)Oleg06 Wrote: http://prntscr.com/bims6w
http://prntscr.com/bimsdp
http://prntscr.com/bimsne

I know what it is (the security check failed), but not sure how to solve it.
It's the same nonce check as GS uses..

In components_ext.php, line 53 - 62 you can see this:

PHP Code:
<?php 
// protect against CSRF, basic check 
if (!isset($USR) || $USR != get_cookie('GS_ADMIN_USERNAME') || !isset($_COOKIE['PHPSESSID'])) 
  die();
        
// only continue if the request comes from the same domain & nonces match
if (empty($_SERVER['HTTP_ORIGIN']) || strpos($_SERVER['HTTP_ORIGIN'], $_SERVER['SERVER_NAME']) < || empty($_GET['nonce']) || !check_nonce($_GET['nonce'], 'components_ext_action''components_ext.php'))
  die(); 

So either:
  • the $USR global is not set or the $USR global does not match GS_ADMIN_USERNAME.
  • the PHPSESSID is not set
  • the $_SERVER['HTTP_ORIGIN'] is not set or $_SERVER['SERVER_NAME'] doesn't appear in [c]$_SERVER['HTTP_ORIGIN'].
  • the $_GET['nonce'] is not set or isn't correct according to check_nonce.
To debug, can you please replace the above lines with the following:

PHP Code:
if (!isset($USR) || $USR != get_cookie('GS_ADMIN_USERNAME')) 
  
$components_ext->response(200, '$USR global missing or GS_ADMIN_USERNAME cookie missing');
if (!isset(
$_COOKIE['PHPSESSID']))
  
$components_ext->response(200, '$_COOKIE[\'PHPSESSID\'] is not set');    
if (empty(
$_SERVER['HTTP_ORIGIN']) || strpos($_SERVER['HTTP_ORIGIN'], $_SERVER['SERVER_NAME']) < 5)
  
$components_ext->response(400, 'Server name mismatch');
if (empty(
$_GET['nonce']))
  
$components_ext->response(400, 'No nonce given');
if (!
check_nonce($_GET['nonce'], 'components_ext_action''components_ext.php'))
  
$components_ext->response(400, 'Nonce mismatch'); 

Try to save again, and see what error message is displayed, thanks
Reply


Messages In This Thread
Components Extended [v0.9.3] - by Tyblitz - 2016-06-14, 05:22:09
RE: [NEW] Components Extended - by shawn_a - 2016-06-14, 06:43:48
RE: [NEW] Components Extended - by datiswous - 2016-06-14, 20:30:25
RE: [NEW] Components Extended - by Tyblitz - 2016-06-18, 05:21:26
RE: [NEW] Components Extended - by Oleg06 - 2016-06-18, 05:47:09
RE: [NEW] Components Extended - by Tyblitz - 2016-06-18, 07:54:33
RE: [NEW] Components Extended - by Tyblitz - 2016-06-18, 08:09:31
RE: [NEW] Components Extended - by Oleg06 - 2016-06-18, 08:25:58
RE: [NEW] Components Extended - by Oleg06 - 2016-06-18, 08:32:27
RE: [NEW] Components Extended - by Tyblitz - 2016-06-18, 08:42:20
RE: [NEW] Components Extended - by Oleg06 - 2016-06-18, 18:17:45
RE: [NEW] Components Extended - by Tyblitz - 2016-06-18, 20:23:49
RE: [NEW] Components Extended - by Oleg06 - 2016-06-18, 21:12:20
RE: [NEW] Components Extended - by Oleg06 - 2016-06-18, 21:15:01
RE: [NEW] Components Extended - by datiswous - 2016-06-20, 19:57:54
RE: [NEW] Components Extended - by Oleg06 - 2016-06-20, 21:06:52
RE: [NEW] Components Extended - by Tyblitz - 2016-06-21, 03:32:14
RE: [NEW] Components Extended - by Oleg06 - 2016-06-21, 05:18:40
RE: [NEW] Components Extended - by shawn_a - 2016-06-21, 06:15:55
RE: [NEW] Components Extended - by Tyblitz - 2016-06-21, 09:06:50
RE: [NEW] Components Extended - by shawn_a - 2016-06-21, 09:45:11
RE: [NEW] Components Extended - by Oleg06 - 2016-06-21, 17:46:25
RE: [NEW] Components Extended - by shawn_a - 2016-06-22, 00:02:10
RE: [NEW] Components Extended - by shawn_a - 2016-06-22, 03:23:09
RE: [NEW] Components Extended - by Tyblitz - 2016-06-22, 06:37:28
RE: [NEW] Components Extended - by Oleg06 - 2016-06-22, 06:40:50
RE: [NEW] Components Extended - by Bigin - 2016-06-22, 19:17:19
RE: [NEW] Components Extended - by shawn_a - 2016-06-23, 00:40:41
RE: [NEW] Components Extended - by Bigin - 2016-06-23, 01:14:06
RE: [NEW] Components Extended - by Bigin - 2016-06-23, 01:33:32
RE: [NEW] Components Extended - by Tyblitz - 2016-06-23, 02:25:21
RE: [NEW] Components Extended - by Bigin - 2016-06-23, 03:00:28
RE: [NEW] Components Extended - by shawn_a - 2016-06-23, 02:40:44
RE: [NEW] Components Extended - by datiswous - 2016-07-04, 20:25:18
RE: [NEW] Components Extended - by datiswous - 2016-09-09, 19:29:30
RE: [NEW] Components Extended - by Tyblitz - 2016-09-12, 08:35:20
RE: [NEW] Components Extended - by datiswous - 2016-09-12, 20:20:02
RE: [NEW] Components Extended - by Tyblitz - 2016-09-23, 08:02:23
RE: [NEW] Components Extended - by Tyblitz - 2016-09-23, 08:50:01
RE: [NEW] Components Extended - by shawn_a - 2016-09-21, 01:57:41
RE: [NEW] Components Extended - by shawn_a - 2016-09-23, 08:44:35
RE: [NEW] Components Extended - by Tyblitz - 2016-09-25, 08:06:21
RE: [NEW] Components Extended - by Oleg06 - 2016-09-26, 06:09:52
RE: [NEW] Components Extended - by Oleg06 - 2016-09-26, 07:05:14
RE: [NEW] Components Extended - by Tyblitz - 2016-09-26, 08:53:16
RE: [NEW] Components Extended - by Tyblitz - 2017-02-22, 08:31:30
RE: Components Extended [v0.9] - by Shasaar - 2017-05-07, 22:25:29
RE: Components Extended [v0.9] - by datiswous - 2018-01-31, 23:54:08
RE: Components Extended [v0.9] - by Tyblitz - 2018-04-24, 07:50:02
RE: Components Extended [v0.9] - by datiswous - 2018-04-25, 05:49:08
RE: Components Extended [v0.9] - by yojoe - 2018-07-17, 07:03:58
RE: Components Extended [v0.9.1] - by Tyblitz - 2019-01-29, 09:18:47
RE: Components Extended [v0.9.1] - by hempelr - 2019-03-20, 23:25:33
RE: Components Extended [v0.9.1] - by datiswous - 2019-03-21, 23:43:40
RE: Components Extended [v0.9.1] - by datiswous - 2019-03-21, 22:57:08
RE: Components Extended [v0.9.1] - by hempelr - 2019-03-22, 18:52:35
RE: Components Extended [v0.9.1] - by datiswous - 2019-03-23, 04:19:16
RE: Components Extended [v0.9.1] - by hempelr - 2019-03-25, 20:02:30
RE: Components Extended [v0.9.1] - by Tyblitz - 2019-03-26, 10:11:14
RE: Components Extended [v0.9.1] - by Tyblitz - 2019-04-08, 08:46:03
RE: Components Extended [v0.9.3] - by datiswous - 2019-04-09, 08:57:52
RE: Components Extended [v0.9.3] - by Tyblitz - 2019-04-10, 01:28:29
RE: Components Extended [v0.9.3] - by poorboy2 - 2020-01-30, 07:09:09



Users browsing this thread: 1 Guest(s)