Simple Machines Community Forum

SMF Support => SMF 1.1.x Support => Topic started by: SlammedDime on December 06, 2008, 10:36:43 AM

Title: SMF 1.1.7: Session verification failed when installing mods or SMF 1.1.8 update
Post by: SlammedDime on December 06, 2008, 10:36:43 AM
Bug #2734: FTP Permissions causes package installation to fail (http://dev.simplemachines.org/mantis/view.php?id=2734)

Unfortunately, it seems that in one of our recent security releases (SMF 1.1.7), the security fix created a bug that may affect some installations of SMF depending on the server configuration.

If you have this problem when upgrading to SMF 1.1.8 or when installing mods on SMF 1.1.7, please use the fix below.

If, after applying this fix, you still have the problem, please try packages on the default theme.  If the problem still persists using the default 'core' theme, please create a new topic, do not post support questions in this topic.

Open Sources/Packages.php

Code (Find) Select
function PackageInstallTest()
{
    global $boarddir, $txt, $context, $scripturl, $sourcedir, $modSettings;

    checkSession('get');


Code (Replace) Select
function PackageInstallTest()
{
    global $boarddir, $txt, $context, $scripturl, $sourcedir, $modSettings;

    checkSession('request');
Title: Re: SMF 1.1.7: Session verification failed error when installing mods
Post by: gietl on December 12, 2008, 10:55:57 AM
Awesome! I was having this problem and this solution worked perfectly.
Title: Re: SMF 1.1.7: Session verification failed error when installing mods
Post by: welshdog on December 13, 2008, 08:49:08 PM
Made no difference to my 'Session Verification Error" issues though I was directed here because my 'vanilla install' rfused to let me access any part of the site whilst 'logged in'.
Title: Re: SMF 1.1.7: Session verification failed error when installing mods
Post by: farzad on December 18, 2008, 09:37:35 AM
worked for me.  thanks!
Title: Re: SMF 1.1.7: Session verification failed error when installing mods
Post by: bujuk on December 18, 2008, 10:47:53 AM
Thanks.  just solve my headache  :D
Title: Re: SMF 1.1.7: Session verification failed error when installing mods
Post by: BaikPunyo on December 19, 2008, 02:20:30 PM
thanks SlammedDime.. It's work 100%
Title: Re: SMF 1.1.7: Session verification failed error when installing mods
Post by: Regashi on December 19, 2008, 06:15:52 PM
derrr
Title: Re: SMF 1.1.7: Session verification failed error when installing mods
Post by: Tyrsson on December 21, 2008, 03:44:18 PM
Could we get this added to the "useful manual links" options for the support volunteers? It sure would help :)
Title: Re: SMF 1.1.7: Session verification failed error when installing mods
Post by: sheryltoo on December 21, 2008, 07:13:03 PM
I'm not sure were I'm suppose to look for that code that needs to be replaced.
Could someone please direct me to the right area?
Thanks.
Sheryl
Title: Re: SMF 1.1.7: Session verification failed error when installing mods
Post by: SlammedDime on December 21, 2008, 08:24:58 PM
Quote from: SlammedDime on December 06, 2008, 10:36:43 AM
Open Sources/Packages.php

Title: Re: SMF 1.1.7: Session verification failed error when installing mods
Post by: waterrat on December 21, 2008, 08:33:27 PM
Thanks for this fix--it worked for one mod install, then I've had problems with every mod install since.  I had to manually add a temp file set to 777 to install any other mods--and even then, the mods read as installed, but aren't.  Is there something I'm missing?

I opened a topic specifically on my issue: http://www.simplemachines.org/community/index.php?topic=281517.0

I just wondered if my problem and is related to the Verification Error or not.
Title: Re: SMF 1.1.7: Session verification failed error when installing mods
Post by: Rebochan on December 21, 2008, 10:20:55 PM
I can't find the text in that .php file.  There's something completely different instead.  I'm using the latest version of SMF.  I *think* this is the right spot - it starts on line 144.  But as you can see, it's nothing like the code in the first post...

function PackageInstallTest()
{
global $boarddir, $txt, $context, $scripturl, $sourcedir, $modSettings;

// You have to specify a file!!
if (!isset($_REQUEST['package']) || $_REQUEST['package'] == '')
redirectexit('action=packages');
$context['filename'] = preg_replace('~[\.]+~', '.', $_REQUEST['package']);

require_once($sourcedir . '/Subs-Package.php');

// Load up the package FTP information?
if (isset($_SESSION['pack_ftp']))
packageRequireFTP($scripturl . '?action=packages;sa=' . $_REQUEST['sa'] . ';package=' . $_REQUEST['package']);
Title: Re: SMF 1.1.7: Session verification failed error when installing mods
Post by: SlammedDime on December 21, 2008, 10:27:31 PM
Rebochan, as I said in the first post , please create your own support topic.

It does not look like you have the 'latest' version of smf... if the top of the file does not say SMF 1.1.7, then you do not.  Please start your own topic though.
Title: Re: SMF 1.1.7: Session verification failed error when installing mods
Post by: J-Bird on December 27, 2008, 01:08:13 PM
After over a month of not getting any resolution on this same problem, I found out my problem is related to the FPS theme.
If I change to the default theme , then I can make changes to the mods, and change back to FPS after.
Perhaps this may help someone else.
Title: Re: SMF 1.1.7: Session verification failed error when installing mods
Post by: gtowntalk on December 28, 2008, 01:37:05 PM
No go. I have reinstall 1x and 2x and tried to follow all "fixes" and none work for  me. I do want to point out that use a linux box with centos 5.2 and my own hosting software (i.e. not cpanel or any of the typicals) and therefore do not use /home/user/public_htem/site...... my sites are /var/www/username/web/site and my ftp is /web/site

When i install smf it keeps reporting that it found my path as /username/web but when i enter all  the other info on the first page of the installation it reports that that path does not exist (it does by the way) but if i remove the [/username] part and just leave [/web] it installs and looks like all is good. but none of the mods will install...i get session verif....error.

any help would be great!! :)
Title: Re: SMF 1.1.7: Session verification failed error when installing mods
Post by: G6™ on December 29, 2008, 12:28:00 PM
From first post
QuoteIf, after applying this fix, you still have the problem, please try packages on the default theme.  If the problem still persists using the default 'core' theme, please create a new topic, do not post support questions in this topic.

From 10th post

QuoteRebochan, as I said in the first post , please create your own support topic.

It does not look like you have the 'latest' version of smf... if the top of the file does not say SMF 1.1.7, then you do not.  Please start your own topic though.
Title: Re: SMF 1.1.7: Session verification failed error when installing mods
Post by: slnurajar on December 29, 2008, 12:39:52 PM
Hi i downloaded smf 1.17 only now, is i need to follow  instructions in this topic and whether this is corected in smf 2.0 beat 4 public
Title: Re: SMF 1.1.7: Session verification failed error when installing mods
Post by: SlammedDime on December 29, 2008, 12:49:34 PM
This will not be fixed until 1.1.8, so yes, you do need to apply this fix if you have the problem.

This currently is not needed for 2.0 Beta 4, thus the title stating 1.1.7.
Title: Re: SMF 1.1.7: Session verification failed error when installing mods
Post by: kushari on December 30, 2008, 12:31:22 AM
amazing worked perfectly!
Title: Re: SMF 1.1.7: Session verification failed error when installing mods
Post by: mortymoose on December 30, 2008, 01:53:24 AM
Thanks 4 That, I was a wee bit worried, works like a boeing!   ;)
Title: Re: SMF 1.1.7: Session verification failed error when installing mods
Post by: woodsters on December 31, 2008, 10:49:39 AM
Echoing Sheryltoo's request. Where do I find the Sources/Packages.php file?
Title: Re: SMF 1.1.7: Session verification failed error when installing mods
Post by: sheryltoo on December 31, 2008, 10:57:29 AM
I can tell you where I found it and hopefully it's in the same place for you.
I first opened my SMF folder at my host site and looked for a folder in that folder called "Sources."
I opened that folder and then looked for the file called "packages.php."
Then you have to scroll down and find the word that needs to be replaced.
BTW, once I changed the word, I was able to install packages so it worked like a charm.
Sheryl
Title: Re: SMF 1.1.7: Session verification failed error when installing mods
Post by: woodsters on December 31, 2008, 10:59:42 AM
Thanks Sheryl...I was hoping I could find it through the Admin section of the forum itself... :(
Title: Re: SMF 1.1.7: Session verification failed error when installing mods
Post by: 6d4vdub on December 31, 2008, 07:16:18 PM
The fix did not work for me, so I renamed Packages.php to Packages1.php

and I renamed Packages.php~ to Packages.php

Now everything is working fine. (so far)  ;D
Title: Re: SMF 1.1.7: Session verification failed error when installing mods
Post by: SlammedDime on December 31, 2008, 07:34:27 PM
Bad idea... that opens you back up to all of the vulnerabilities in 1.1.6.

If it didn't work for you, open a new support topic about the issue.
Title: Re: SMF 1.1.7: Session verification failed error when installing mods
Post by: Sabre™ on December 31, 2008, 07:39:17 PM
Warning - while you were typing a new reply has been posted. You may wish to review your post.

[ previous comment deleted, as was beaten to it!! ]  lol 

I havent had this problem yet, but cheers for the fix mate :)
Title: Re: SMF 1.1.7: Session verification failed error when installing mods
Post by: 6d4vdub on December 31, 2008, 08:22:33 PM

Quote from: 6d4vdub on December 31, 2008, 07:16:18 PM
The fix did not work for me, so I renamed Packages.php to Packages1.php

and I renamed Packages.php~ to Packages.php

Now everything is working fine. (so far)  ;D

Sorry, I was WRONG,  I can now install my old packages that are in Package Manger, but I still can't see my new uploaded packages in Package Manager.

I guess i'll change it back like SlammedDime said and just hang till 1.1.8
Title: Re: SMF 1.1.7: Session verification failed error when installing mods
Post by: virajsam on January 01, 2009, 06:16:23 AM
it solve one problem but still having one error

550 Can't change directory to /home/a8418699/public_html: No such file or directory
Title: Re: SMF 1.1.7: Session verification failed error when installing mods
Post by: N3RVE on January 01, 2009, 05:28:59 PM
I'll lock this topic. You can start a new topic for your problem (if any) and we'll get to it.

-[n3rve]