ikiwiki/IkiWiki
Joey Hess 72b5ef2c5f Fix CSRF attacks against the preferences and edit forms. Closes: #475445
The fix involved embedding the session id in the forms, and not allowing the
forms to be submitted if the embedded id does not match the session id.

In the case of the preferences form, if the session id is not embedded,
then the CGI parameters are cleared. This avoids a secondary attack where the
link to the preferences form prefills password or other fields, and
the user hits "submit" without noticing these prefilled values.

In the case of the editpage form, the anonok plugin can allow anyone to edit,
and so I chose not to guard against CSRF attacks against users who are not
logged in. Otherwise, it also embeds the session id and checks it.

For page editing, I assume that the user will notice if content or commit
message is changed because of CGI parameters, and won't blndly hit save page.
So I didn't block those CGI paramters. (It's even possible to use those CGI
parameters, for good, not for evil, I guess..)

The only other CSRF attack I can think of in ikiwiki involves the poll plugin.
It's certianly possible to set up a link that causes the user to unknowingly
vote in a poll. However, the poll plugin is not intended to be used for things
that people would want to attack, since anyone can after all edit the poll page
and fill in any values they like. So this "attack" is ignorable.
2008-04-10 16:35:30 -04:00
..
Plugin need to handle urls to images the same 2008-04-03 16:37:05 -04:00
Rcs truncate recentchangesdiffs after 200 lines 2008-03-12 15:45:10 -04:00
Setup * Correct a longstanding bug that could cause the edit form to be empty. 2007-06-30 00:48:39 +00:00
CGI.pm Fix CSRF attacks against the preferences and edit forms. Closes: #475445 2008-04-10 16:35:30 -04:00
Render.pm Added a hardlink option in the setup file, useful if the source and dest are on the same filesystem and the wiki includes large media files, which would normally be copied, wasting time and space. 2008-03-29 21:02:47 -04:00
Setup.pm * Better error message when a setup file has a syntax error. 2007-11-17 14:06:11 -05:00
UserInfo.pm Store userinfo in network byte order for easy portability. (Old files will be automatically converted.) 2008-03-19 22:46:51 -04:00
Wrapper.pm * Removed support for sending commit notification mails. Along with it went 2008-01-29 00:36:58 -05:00