FTP text in page topic causes failure in 2.7.1

FTP text in page topic causes failure in 2.7.1

by Alisdair Gurney -
Number of replies: 10

I'm using Moodle 2.7.1

I added a page to one of my courses using, as I often do,  Add Activity or Resource -> Page

I spent a long time trying to identify why one of my courses was failing to save, and the result was bizarre:

The page content had a sentence that contained "FTP" and that was enough to cause it to fail!

It's easily reproducible, but I've never seen it before, yet it's an acronym I must have used in the past.

Does this happen for anyone else? Is it a known problem?









 

Attachment FTP.png
Average of ratings: -
In reply to Alisdair Gurney

Re: FTP text in page topic causes failure in 2.7.1

by Mary Cooch -
Picture of Documentation writers Picture of Moodle HQ Picture of Particularly helpful Moodlers Picture of Testers Picture of Translators

I've seen this error reported in the forums before (not your specific FTP terms but other similar, harmless-looking words) and it often relates to mod_security  - I would do a search on these forums for mod_security and/or "You don't have permission to access " and see if it brings you some useful information.

In reply to Mary Cooch

Re: FTP text in page topic causes failure in 2.7.1

by Alisdair Gurney -

Thanks, but I've had no success with mod_security, although it does sound a likely candidate.
Other words that stop an activity being uploaded are "control" and "services", I'm sure there are plenty more; the upload also fails if the words are in the Description.

Here's a sample message from the apache error log that's triggered when uploading text containing one of the above words (no sign of mod_security):

[Tue Mar 24 12:20:08 2015] [error] [client xx.my.ip.xx] Default exception handler: Invalid action parameter Debug: \nError code: invalidaction\n* line 463 of /lib/setuplib.php: moodle_exception thrown\n* line 234 of /course/modedit.php: call to print_error()\n, referer: http://mysite.com/course/modedit.php?update=2884&return=0&sr=0


In reply to Alisdair Gurney

Re: FTP text in page topic causes failure in 2.7.1

by Ken Task -
Picture of Particularly helpful Moodlers

Can't replicate the issue using just FTP text ... in convering URL's into links, ftp:// doesn't see to work but http:// does.

Check filters:

site administrator in Settings > Site administration > Plugins > Filters > Convert URLs into links and images.

Is it on?  Leave it on.

Go to the course.   Is there a 'filters' link in the course menu?   If so, follow it, turn off filters for that course that are on ... all of them.

Then check to see if you can access the page containing FTP.

If you can edit the page creating the problem, might have to attempt to reach it via direct URL:

http://mysite.com/course/modedit.php?update=2884 or something like that!

Version you are running is behind ... the highest of 2.7.x might provide a fix.

'spirit of sharing', Ken


In reply to Ken Task

Re: FTP text in page topic causes failure in 2.7.1

by Visvanath Ratnaweera -
Picture of Particularly helpful Moodlers Picture of Translators
Could it be two text filters colliding, an auto-linking glossary and the URL auto-linking?
In reply to Visvanath Ratnaweera

Re: FTP text in page topic causes failure in 2.7.1

by Alisdair Gurney -

Filters aren't on, and there's no URL. The "FTP" was simply a word in a sentence about networking

thanks anyway


In reply to Ken Task

Re: FTP text in page topic causes failure in 2.7.1

by Alisdair Gurney -

Thanks for the thoughts. Filters aren't enabled, and changing them makes no difference

There's no problem editing the page, but if the text contains the word "control" or "service" or "ftp" it fails to save.

Hopefully upgrading will fix it

thanks again





In reply to Alisdair Gurney

Re: FTP text in page topic causes failure in 2.7.1

by David Richards -
Maybe bumping up debugging to a higher level and see if you can get a more detailed error message?

https://docs.moodle.org/27/en/Debugging

Post errors here if you get anything new.
In reply to David Richards

Re: FTP text in page topic causes failure in 2.7.1

by Alisdair Gurney -

sadly even setting Developer level messaging provides no more illumination

thanks

In reply to Alisdair Gurney

Re: FTP text in page topic causes failure in 2.7.1

by Ken Task -
Picture of Particularly helpful Moodlers

Think you are going to have to disclose some more info ... about server setting and about modules loaded for apache/php.   Remotely hosted?  If so, what provider?

That sounds like a network filter of some sort!

Got anything installed in your browser?   Running a Proxy?

How about apache error logs?

'spirit of sharing', Ken


In reply to Ken Task

Re: FTP text in page topic causes failure in 2.7.1

by Alisdair Gurney -

Solved, network filtering looks like being the culprit!

My eLearning system's hosted on our corporate network - connecting via VPN lets those terms through, so it's nothing to do with Moodle.

Thanks