jeffalo / my-ocular

backend for ocular
https://ocular.jeffalo.net/docs/about#what-iswas-my-ocular
9 stars 10 forks source link

Add a filter #20

Closed LankyBox01 closed 3 years ago

LankyBox01 commented 3 years ago

Is your feature request related to a problem? Please describe. Yes. I can write profanity in my status.

(image removed)

Describe the solution you'd like There should be a message saying that the status failed to update. Maybe try my anti-profanity plugin to detect it. https://github.com/CodeGuy92/anti-profanity

Describe alternatives you've considered No alternatives.

Additional context No additional context.

FunctionalMetatable commented 3 years ago

remove that image i am begging you its very bad

LankyBox01 commented 3 years ago

remove that image i am begging you its very bad

ok i guess

Shluffy commented 3 years ago

an anti-profanity plugin makes sense. however, how do you make changes to that file? jeffalo might not want to filter crap because it is allowed on the scratch website (in some cases), but filter lmao because they feel that it should be filtered (like za-chary). The idea of a filter seems pretty good overall though, and I might use it in my own projects (RandomCode paragraph thing).

why does removing the image make a difference? the repo will use words like that in the readme anyway? although maybe add a note at the top about that? and i still have it in my inbox....

Shluffy commented 3 years ago

@CodeGuy92 you should delete revision content as well

Shluffy commented 3 years ago

or @jeffalo should be able to do it

LankyBox01 commented 3 years ago

an anti-profanity plugin makes sense. however, how do you make changes to that file? jeffalo might not want to filter crap because it is allowed on the scratch website (in some cases), but filter lmao because they feel that it should be filtered (like za-chary). The idea of a filter seems pretty good overall though, and I might use it in my own projects (RandomCode paragraph thing).

why does removing the image make a difference? the repo will use words like that in the readme anyway? although maybe add a note at the top about that? and i still have it in my inbox....

https://scratch.mit.edu/users/LankyBox01/#comments-148898413 I am also planning to add a function to whitelist words (take them out of the blacklist) along with this, later this day

@CodeGuy92 you should delete revision content as well

i did

LankyBox01 commented 3 years ago

an anti-profanity plugin makes sense. however, how do you make changes to that file? jeffalo might not want to filter crap because it is allowed on the scratch website (in some cases), but filter lmao because they feel that it should be filtered (like za-chary). The idea of a filter seems pretty good overall though, and I might use it in my own projects (RandomCode paragraph thing). why does removing the image make a difference? the repo will use words like that in the readme anyway? although maybe add a note at the top about that? and i still have it in my inbox....

https://scratch.mit.edu/users/LankyBox01/#comments-148898413 I am also planning to add a function to whitelist words (take them out of the blacklist) along with this, later this day

e Here's a quick preview of my progress so far. It's live and it works now!

LankyBox01 commented 3 years ago

https://github.com/jeffalo/my-ocular/pull/21

LankyBox01 commented 3 years ago

FunctionalMetatable is right. i dont think this works anyways, filterWords is not defined.

(I'm not intending to sound rude) Yes, it actually does work actually. If you even read my post OR the docs, you'd know that you have to import the script first.

e

cobaltt7 commented 3 years ago

FunctionalMetatable is right. i dont think this works anyways, filterWords is not defined.

(I'm not intending to sound rude) Yes, it actually does work actually. If you even read my post OR the docs, you'd know that you have to import the script first.

e

if you make a pr you should make sure it works. so you're supposed to do that


I say copy LLK/s2forums' bad word detector regular expression because ocular is for the forums. https://github.com/LLK/s2forums/blob/04dc6c7b7a74ce89ecf6c3d9a4a650d59913b038/djangobb_forum/scratchr2_settings.py#L36

LankyBox01 commented 3 years ago

FunctionalMetatable is right. i dont think this works anyways, filterWords is not defined.

(I'm not intending to sound rude) Yes, it actually does work actually. If you even read my post OR the docs, you'd know that you have to import the script first. e

if you make a pr you should make sure it works. so you're supposed to do that

I did. The thing is, jeffalo said he thinks it doesn't work, i'm not sure if he even tested it locally.

LankyBox01 commented 3 years ago

I say copy LLK/s2forums' bad word detector regular expression because ocular is for the forums. https://github.com/LLK/s2forums/blob/04dc6c7b7a74ce89ecf6c3d9a4a650d59913b038/djangobb_forum/scratchr2_settings.py#L36

You can easily bypass it by replacing letters with numbers, or just 𝓯π“ͺ𝓷𝓬𝔂 text. Mine is anti-by-pass and has way more words from different countries.

cobaltt7 commented 3 years ago

You did not import it. And I can tell it does not work.

If its good enough for the scratch forums, it's good enough for ocular imo


From: LankyBox01 @.> Sent: Friday, July 2, 2021 3:53:57 AM To: jeffalo/my-ocular @.> Cc: Paul Reid @.>; Comment @.> Subject: Re: [jeffalo/my-ocular] Add a filter (#20)

I say copy LLK/s2forums' bad word detector regular expression because ocular is for the forums. https://github.com/LLK/s2forums/blob/04dc6c7b7a74ce89ecf6c3d9a4a650d59913b038/djangobb_forum/scratchr2_settings.py#L36

The thing is, you can easily bypass it.

β€” You are receiving this because you commented. Reply to this email directly, view it on GitHubhttps://github.com/jeffalo/my-ocular/issues/20#issuecomment-872835107, or unsubscribehttps://github.com/notifications/unsubscribe-auth/AOT5DEUYV3IZAOZR76UGFQ3TVV5CLANCNFSM47VG3CZQ.

jeffalo commented 3 years ago

my issue is that once theres a filter, people will try bypassing the filter. i will need a very good fitler, and i'll probably just use something from NPM.

LankyBox01 commented 3 years ago

my issue is that once theres a filter, people will try bypassing the filter. i will need a very good fitler, and i'll probably just use something from NPM.

uhh... i tried 4 different filters, and they're easy to bypass. Like, there's literally no by-pass protection at all. You can say things like "b_a_d__w_o_r_d" or 𝓫π“ͺ𝓭 𝔀𝓸𝓻𝓭

jeffalo commented 3 years ago

exactly.

LankyBox01 commented 3 years ago

exactly.

so why do you still want a filter from npm if they don't have bypass protection?

FunctionalMetatable commented 3 years ago

very easy to make proper filter without duplicating stuff

LankyBox01 commented 3 years ago

very easy to make proper filter without duplicating stuff

I did, so you don't have to.

LankyBox01 commented 3 years ago

So are we gonna do this or not?

jeffalo commented 3 years ago

So are we gonna do this or not?

not right now.