Page 1 of 1

adding BBCode, getting 403 error

Posted: Sun Mar 13, 2011 2:28 am
by cascadeorca
So I'm trying to add some custom BBCodes, specifically [spoiler] and maybe [youtube] as well as a thumbnail image code.

I can add codes, as long as the html replacement does not excede 2 sets of brackets. Otherwise it will 403 on me.

A functional example for the HTML replacement would be:

Code: Select all

<b>{text}</b>
An erroring example would be anything with more than 2 sets of brackets, example:

Code: Select all

<b><u>{text}</u></b>
Any help would be greatly appreciated, thanks!

The specific error I am receiving is:

403 Forbidden
You don't have permission to access /forum/adm/index.php on this server.

Additionally, a 404 Not Found error was encountered while trying to use an ErrorDocument to handle the request.

Re: adding BBCode, getting 403 error

Posted: Sun Mar 13, 2011 7:10 am
by Mick
I'm fairly certain you can't use nested brackets like that. There's a whole ruck of information in this sticky here that should help. Incidentally, why would you want to create new BBCodes when they already exist?

I'm not sure why you're getting the 404 error though, you would normally get "Your BBCode is constructed in an invalid form." if there was something wrong with your BBCode syntax.

Re: adding BBCode, getting 403 error

Posted: Sun Mar 13, 2011 10:28 am
by cascadeorca
I guess my phpbb I installed didn't come default with youtube, spoiler, and resized images. Is it supposed to? Mine only came with what I thought was the default: bold, italic, underline, quote, code, list, list=, [*], img, url, and flash.

I was just using bold and italic as examples of multiple code examples, a more true example of a fail and a succeed would be:

(very simple spoiler text-only code)Submits successfully:

Code: Select all

<font style="background:black; color:black">{TEXT}</font>
(youtube code) 403 & 404 errors and refuses submission:

Code: Select all

<object type="application/x-shockwave-flash" data="http://www.youtube.com/v/{IDENTIFIER}" width="425" height="350">
<param name="movie" value="http://www.youtube.com/v/{IDENTIFIER}" />
<param name="wmode" value="transparent" />
</object>

Re: adding BBCode, getting 403 error

Posted: Sun Mar 13, 2011 10:46 am
by Brf
403 errors like that are usually caused by mod_security, where your host is blocking certain combinations of symbols.

Re: adding BBCode, getting 403 error

Posted: Sun Mar 13, 2011 11:40 am
by cascadeorca
oh interesting.

Do you know what kind of thing I would say to my server provider to possibly get this resolved?

Thank you!

Re: adding BBCode, getting 403 error

Posted: Sun Mar 13, 2011 5:56 pm
by Mick
cascadeorca wrote:I guess my phpbb I installed didn't come default with youtube, spoiler, and resized images. Is it supposed to? Mine only came with what I thought was the default: bold, italic, underline, quote, code, list, list=, [*], img, url, and flash.
The three you quote aren't supplied but there are examples of the custom BBCodes (youtube and spoiler) in the link I provided and you would need a mod for resizing images, this, ReIMG Image Resizer, works very well.

Re: adding BBCode, getting 403 error

Posted: Sun Mar 13, 2011 10:46 pm
by Brf
cascadeorca wrote:Do you know what kind of thing I would say to my server provider to possibly get this resolved?
Show them the code you are trying to output and tell them their mod_security is blocking it.

Re: adding BBCode, getting 403 error

Posted: Sun Mar 13, 2011 11:49 pm
by cascadeorca
Brf wrote:
cascadeorca wrote:Do you know what kind of thing I would say to my server provider to possibly get this resolved?
Show them the code you are trying to output and tell them their mod_security is blocking it.
awesome, I sent them a message and hopefully will hear back soon-ish.

Re: adding BBCode, getting 403 error

Posted: Sun Mar 13, 2011 11:50 pm
by cascadeorca
Mixstar wrote:
cascadeorca wrote:I guess my phpbb I installed didn't come default with youtube, spoiler, and resized images. Is it supposed to? Mine only came with what I thought was the default: bold, italic, underline, quote, code, list, list=, [*], img, url, and flash.
The three you quote aren't supplied but there are examples of the custom BBCodes (youtube and spoiler) in the link I provided and you would need a mod for resizing images, this, ReIMG Image Resizer, works very well.

Thanks for the supplied codes.

I will absolutely use them when I manage to fix this 403 and 404 error involved with the implimentation of them. :)

Re: adding BBCode, getting 403 error

Posted: Mon Mar 14, 2011 12:17 am
by cascadeorca
is having mod_security disabled a bad thing?

disabling it definitely fixed the problem.

If I re-implimented mod_security after I made all my changes, would that theoretically hault the changes from functioning?

It seems like mod_security helps to prevent hacking, which I'm all for. But if I can't make the forum work right, then hacking isn't my biggest concern. Can I have my cake and eat it too?

Re: adding BBCode, getting 403 error

Posted: Mon Mar 14, 2011 11:05 am
by Brf
There are no known exploits for the current version of phpBB, so mod_security is not needed. If you are allowed to disable mod_security using the php.ini file, I would disable it for just the phpBB folders.

Re: adding BBCode, getting 403 error

Posted: Mon Aug 22, 2016 5:36 pm
by Wulfric
I have mode security disabled, yet i keep getting error when adding an iframe BBCODE

Code: Select all

[iframe]{URL}[/iframe]

Code: Select all

<iframe src="{URL}" height="600" width="800" frameborder="0"></iframe>

Re: adding BBCode, getting 403 error

Posted: Mon Aug 22, 2016 6:09 pm
by Lumpy Burgertushie
what error? link to the board and the post where you are trying to use this bbcode please.

might be better to start a new topic for your problem and Please fill out the Support Request Template Generator and post it back here to enable us to assist you better.


robert