Wakaba/Kareha patches (107)

1 Name: Anonymous : 2009-10-22 16:08 ID:0RX4zZms [Del]

Wakaba and Kareha are refreshingly malleable, and I find it surprising that there isn't already a thread for all the "extras" can be patched onto a board, so here goes.

For the record, here are some existing patches on this board:

58 Name: Anonymous : 2011-10-02 14:41 ID:oJF9allQ [Del]

>>57 It output's:

Can't locate Captcha/reCAPTCHA.pm in @INC...

Should I reinstall? I've searched Google, no helpful information.

59 Name: Anonymous : 2011-10-02 14:49 ID:Heaven [Del]

>>58
How did you install it? I use Debian and installing it through the package manager always worked for me. Using CPAN left out a dependency or two.

60 Post deleted by user.

61 Name: Anonymous : 2011-10-02 15:26 ID:oJF9allQ [Del]

I decided to reinstall it via the package manager, and I don't receive that error anymore, but now it's saying the verification code is wrong even when it's correct. I've tried it with 10+ different codes.

62 Name: Anonymous : 2011-10-02 15:51 ID:Heaven [Del]

>>61
I can't help you with that one. Only thing I can think of is the public/private keys being incorrect, or your server being unable to connect to Google's servers.

63 Post deleted by user.

64 Name: Anonymous : 2011-10-06 00:18 ID:oJF9allQ [Del]

>>62

Adding onto my previous post;

Before:

make_error(S_BADCAPTCHA) unless $result->{is_valid};

I added:

print $result->{is_valid};

and it printed the source code of the page.

65 Name: Anonymous : 2011-10-08 14:48 ID:oJF9allQ [Del]

>>62

I really need help with this. I've tried everything. All the keys are correct, I've even tried it on a clean install.

66 Post deleted by moderator.

67 Post deleted by moderator.

68 Name: Anonymous : 2011-10-10 18:27 ID:oJF9allQ [Del]

>>62

Anyone at all? I've tried literally hundreds of things.

69 Name: Anonymous : 2011-10-11 11:46 ID:mWq75Fd3 [Del]

>>68
Hi,

I've taken the time to trace the problem, and I think I have a fix (but as usual, I'm too lazy to test it until anyone whines about it):

Find:

my $challenge=$query->param("challenge");
my $response=$query->param("response");

and replace it with:

my $challenge=$query->param("recaptcha_challenge_field");
my $response=$query->param("recaptcha_response_field");

That should hopefully do the trick. Obviously it was a derp on my part, I'll create an updated patch soon to rectify this.

70 Name: Anonymous : 2011-10-11 12:03 ID:mWq75Fd3 [Del]

Also, why do you even need reCAPTCHA that desperately? The default CAPTCHA is fine, easy to fill out, hard for bots to break and can easily be tweaked if you need better anti-bot measures.

If you're trying to cope with spam, I think you'll find that many of those so-called bots are actually humans.

71 Name: Anonymous : 2011-10-11 19:43 ID:oJF9allQ [Del]

>>69

Ok, now I don't get "Error: Wrong verification code entered.", but it doesn't post the message. I've rebuild the caches, but no avail.

>>70

It's definitely bots. Unless the same human is posting 20+ messages a second.

72 Name: Anonymous : 2011-10-12 06:58 ID:mWq75Fd3 [Del]

>>71

>Ok, now I don't get "Error: Wrong verification code entered.", but it doesn't post the message. I've rebuild the caches, but no avail.

That's weird. I just tested the fix myself, and it works perfectly for me. Did you try fixing this on a clean install?

>It's definitely bots. Unless the same human is posting 20+ messages a second.

Uh, okay.

73 Name: Anonymous : 2011-10-12 17:41 ID:oJF9allQ [Del]

>>72

I found the issue (Well a fix at least).

I added:

build_cache();

after:

make_cookies...

74 Name: sly : 2011-10-30 16:02 ID:v57DkBCQ [Del]

>>53
this is what i'm trying to accomplish. where do you change the redirect call? i've tried changing it in every call to make_http_forward i can find, but it doesn't work for me unless I put it in the actual function...

sub make_http_forward($;$)
{

my ($location,$alternate_method)=@_;

$location = "http://website/index.php?board=Main"; // <--- this is awful.

if($alternate_method)
{

...

75 Name: Anonymous : 2011-11-07 11:26 ID:fQVv0m/Z [Del]

I've always wondered why people thought noko was pointless. If anything it makes navigation easier. Shit, nobody even knows if you use it or not. I already wrote a noko patch for wakaba (a bit different than the one in this thread) and I'm planning on adding noko to Kareha as well. Anyone interested in a patch?

76 Name: Anonymous : 2011-11-08 17:08 ID:Heaven [Del]

> I've always wondered why people thought noko was pointless.

it's because pretty much all browsers have a back button.

> Shit, nobody even knows if you use it or not.

yes, they do, because you usually can't use noko and sage at the same time.

77 Name: Anonymous : 2011-11-09 21:02 ID:fQVv0m/Z [Del]

>>76
Pretty sure nokosage exists, at least in Yotsuba.

78 Post deleted by moderator.

79 Name: Anonymous : 2011-11-12 10:27 ID:UzTuYUYa [Del]

>>76

When you use the back button usually you don't see the latest posts.

80 Name: Anonymous : 2011-11-12 14:44 ID:Heaven [Del]

>>79
that's what the reload button is for.

81 Post deleted by user.

82 Name: Anonymous : 2011-12-17 12:23 ID:8dN4H3I2 [Del]

>>80
>>79
Nobody uses the web this way aside from 50 year olds. noko is useful.

83 Name: Anonymous : 2011-12-21 12:22 ID:9ObHjNsb [Del]

>>50 actual code fixes! thanks.

84 Name: Anonymous : 2011-12-26 19:30 ID:Heaven [Del]

>>82
everyone uses the web this way aside from /b/tards. if you think noko is so useful, just write a tiny bit of javascript to implement it in your browser.

85 Name: Anonymous : 2011-12-26 23:44 ID:8dN4H3I2 [Del]

>>84
I already implemented it in Wakaba, and most message boards and forums have the feature built in and enabled by default.

86 Name: Anonymous : 2012-01-15 15:43 ID:1UnSRfFr [Del]

This isn't actually a patch, but since I made it with Wakaba in mind, I'll post about it anyway.

I've created a wrapper for running CGI scripts on hosts with PHP that for some reason can't run regular CGI scripts. This means that if your host has Perl installed (more than likely, since it's included with all major Linux distros) and hasn't disabled proc_open() (which many shitty hosts tend to do for some reason), then it will be able to run Kareha and possibly Wakaba using this wrapper. Wakaba is less likely to run because it depends on the DBI module and database drivers which aren't included with the standard Perl distribution. Kareha depends only on core modules and will run perfectly fine nearly everywhere.

If you've been wanting to use Wakaba or Kareha, but your (crappy) host doesn't support CGI, I suggest trying this. It's especially useful with Kareha, since all the PHP-based textboard scripts suck.

87 Name: !WAHa.06x36 : 2012-01-15 15:57 ID:Heaven [Del]

>>86

Hey, you made PHPerl, which I never got around to making. GJ.

88 Name: Anonymous : 2012-02-05 14:57 ID:lrw7jQEH (Image: 0x0 patch, 0 kb) [Del]

Anyone running a Wakaba board ought to read this.

There's a serious vulnerability in Wakaba 3.0.8 and below which let's anyone inject whatever HTML they want to in posts. This can be fixed by removing a couple of lines in the get_decoded_hashref() and get_decoded_arrayref() subroutines in wakaba.pl, as shown in the included patch file. There should be no problem in making these changes.

Board moderators with no access to the board files may add /chr\([0-9]/ to spam.txt in order to fix the problem.

89 Name: !WAHa.06x36 : 2012-02-05 18:19 ID:q5Et8xfu [Del]

>>88

Looks like that is there to work around some absurdity in MySQL. I supposed MySQL has since changed and is now doing the wrong thing?

I'll put together a 3.0.9.

90 Name: !WAHa.06x36 : 2012-02-05 18:38 ID:Heaven [Del]

91 Name: Anonymous : 2012-02-05 21:55 ID:Heaven [Del]

>>90
Brilliant, thanks mate.

92 Name: Anonymous : 2012-03-16 05:42 ID:Heaven [Del]

did anyone ever implement svg thumbnailing?

93 Name: Anonymous : 2012-05-12 21:50 ID:Heaven [Del]

I'm sure someone did.

94 Name: Anonymous : 2013-01-13 12:16 ID:MLW+MHfx [Del]

>>49
How can this be used in Wakaba?

95 Name: becauseICan : 2013-05-26 13:00 ID:bTAo78dV [Del]

Pay no attention to the devs that tell you that you don't need something, such as noko. They seem to be into some weird sub/dom kink and want the world to bend their way. Just fork their code and make it better.

96 Name: Anonymous : 2013-05-28 08:51 ID:Heaven [Del]

>>95
Or you know, they could just not feel obligated to bend to your every need.

97 Name: Anonymous : 2013-07-13 22:45 ID:Heaven [Del]

> Just fork their code and make it better.

The sort of people who want things like noko aren't capable of that.

98 Name: Anonymous : 2013-07-17 12:30 ID:r9kThGPr (Image: 0x0 , 3 kb) [Del]

Just did these for a guy in another thread, but I might as well post them here to keep things organized

Hold back posts for moderation 1/2

99 Name: Anonymous : 2013-07-17 12:31 ID:r9kThGPr (Image: 0x0 , 9 kb) [Del]

Hold back posts for moderation 2/2

100 Name: Anonymous : 2013-08-15 18:53 ID:sOmyVriI [Del]

>>98>>99 amazing, thanks. might want to add how to add the new column to existing DBs.

101 Name: Anonymous : 2013-08-15 19:40 ID:Heaven [Del]

>>100
Just do ALTER TABLE comments ADD approved TINYINT; in the sql interface

102 Name: Anonymous : 2013-08-16 07:26 ID:sOmyVriI [Del]

>>101 Not for me, for others :p

I do get this error when I click an approve link within the admin panel:

DBD::mysql::st fetchrow_hashref failed: fetch() without execute() at wakaba.pl line 2066

Ignore the line number, my copy is modded.

sub get_decoded_arrayref($)
{
my ($sth)=@_;

my $row=$sth->fetchrow_arrayref();

That's the issue line.

103 Name: Anonymous : 2013-08-16 07:58 ID:Heaven [Del]

>>102
No idea. Are you using SQLite or a regular mysql database? I've only tested this on SQLite. Also, did you try to run the actual patch on your modded wakaba.pl? That could very well be the issue.

104 Name: Anonymous : 2013-08-16 08:49 ID:sOmyVriI [Del]

The mod works, it just also throws that error into the error log. It's just MySQL.

105 Name: Anonymous : 2017-04-07 00:10 ID:XRpHSYu/ [Del]

What happended to this site? Everything I see here is so old :(

AND I have no clue about how to get kareha running.

106 Name: Anonymous : 2017-04-16 15:20 ID:TmtafiOh [Del]

>>105
Wakaba is mostly mature at this point. There really isn't too much to do to Wakaba to make it a futaba channel clone so therefore, there really isn't much to discuss. I suppose it would be nice to update Wakaba and Kareha to make it HTML5 semantic.

107 Name: Anonymous : 2017-05-11 21:47 ID:YtdEKxxt [Del]

>>105

> AND I have no clue about how to get kareha running.

Take the files from /mode_message (for textboard) or /mode_image (for imageboard, with threads that restart with 1) and put them in the main index.

Name: Link:
Leave these fields empty (spam trap):
More options...
Verification: