[ / / / / / / / / / / / / / ] [ dir / dempart / feet / hypno / jenny / komica / monarchy / vichan / vril ][Options][ watchlist ]

/tech/ - Technology

You can now write text to your AI-generated image at https://aiproto.com It is currently free to use for Proto members.
Email
Comment *
Verification *
File
Select/drop/paste files here
Password (Randomized for file and post deletion; you may also set your own.)
* = required field[▶ Show post options & limits]
Confused? See the FAQ.
Expand all images

File (hide): f4aba6f468c394e⋯.mp4 (6.35 MB, 480x480, 1:1, you are complicit.mp4) (h) (u) [play once] [loop]

[–]

 No.1042129>>1042159 >>1042362 >>1042404 >>1042658 [Watch Thread][Show All Posts]

Got bored so I wrote a script for doing the dnsbls from your terminal, it'll spit the image out to /tmp/captcha.png and it'll display it with the command specified with the -d flag if specified.


#!/bin/bash
while getopts ":d:h" opt; do
case "$opt" in
d)
display_command="$OPTARG"
;;
h)
echo "Usage: dnsbls [-h] [-d IMAGE_DISPLAY_COMMAND]"
exit 255
esac
done


function Captcha {
dnsbls_url="https://8ch.net/dnsbls_bypass.php"
html=$(curl $dnsbls_url 2>/dev/null)
echo "$html"
}

function Captcha_id {
captcha="$1"
echo "$captcha" | grep -oP "(?<=value=['\"])[\S]+(?=['\"])"
}

function Captcha_image {
captcha="$1"
outfile="$2"
echo "$captcha" | grep -oP '(?<="data:image\/png;base64,)[\S]+(?=">)' | base64 -d > "$2"
}

function Captcha_submit {
captcha="$1"
captcha_text="$2"
captcha_id=$(Captcha_id "$captcha")

status="$(curl --output /dev/null -w %{http_code} -s --data "captcha_text=$captcha_text&captcha_cookie=$captcha_id" https://8ch.net/dnsbls_bypass.php)"

if [ "$status" -eq 200 ]
then
return 0
else
return 255
fi
}

captcha="$(Captcha)"
Captcha_image "$captcha" "/tmp/captcha.png"

if [ "$display_command" != "" ]
then
$display_command /tmp/captcha.png &
read answer
display_process=$!
kill -15 "$display_process" 2>/dev/null
else
read answer
fi

Captcha_submit "$captcha" "$answer"

 No.1042136>>1042138

>something with no point

<I got tired of 8chan captchaing my browser so I made them captcha my operating system instead

w o w


 No.1042137

you wrote all that code before even coming up with a basic logo?


 No.1042138

File (hide): 13422ee90ca5169⋯.png (46.47 KB, 321x323, 321:323, thinking emoji.png) (h) (u)

>>1042136

Are you disabled?


 No.1042159

>>1042129 (OP)

Thanks anon. Also the video is humorous.


 No.1042171>>1042174

That's fucking useless. Looking up painless suicide methods would've been a better use of your time


 No.1042174>>1042219

>>1042171

It's only useless if you're stupid.


 No.1042219


 No.1042332>>1042335 >>1042362

>https://8ch.net/dnsbls_bypass.php

What is the purpose of this page?


 No.1042335

>>1042332

That's the page that's framed in when you need to solve the captcha once a day to post.


 No.1042362>>1042403

>>1042129 (OP)

When using the hidden service like you are doing in your script, I rarely have to fill out captchas. This is kind of pointless.

>>1042332

It's for filling out captchas when you don't have javascript enabled. If you have javascript enabled, you will get a pop up when you try to post.


 No.1042403

>>1042362

>When using the hidden service like you are doing in your script, I rarely have to fill out captchas. This is kind of pointless.

What is this "hidden service" you are talking about? And how does using this hidden service reduce the need to fill out captchas?

The script is definitely useful in my opinion. There are browsers that do not display the captcha, even if you go to https://8ch.net/dnsbls_bypass.php.


 No.1042404>>1042413

>>1042129 (OP)

txs anon

>h)

> echo "Usage: dnsbls [-h] [-d IMAGE_DISPLAY_COMMAND]"

> exit 255


#default to showing usage on wrong use of command:
[h,*])
echo "Usage: dnsbls [-h] [-d IMAGE_DISPLAY_COMMAND]"
exit 255

I can't recall if the syntax is correct since it's been a while, but you get the idea


 No.1042413

>>1042404

Oh awesome didn't know that, thanks


 No.1042511>>1042514 >>1042582 >>1042857

File (hide): 7c7dafcb950a78c⋯.mp4 (231.23 KB, 640x480, 4:3, 2019-03-17-14-31.mp4) (h) (u) [play once] [loop]

My take


#!/bin/sh
# TCL \
exec tclsh8.6 "$0" ${1+"$@"}

package require http
package require tls
http::register https 443 tls::socket

proc submit {} {
set captcha_info [::http::formatQuery \
captcha_text [string trim [::.input get]] \
captcha_cookie $::cookie]
set tok [::http::geturl https://8ch.net/dnsbls_bypass.php \
-query $captcha_info]
upvar #0 $tok state
if {$state(status) ne "ok"} {
puts $state(staus)
exit 1
} elseif [regexp {You failed the CAPTCHA.} $state(body)] {
set ans [tk_dialog .assd "Failure" "Try Again?" warning 0 No Yes]
if {$ans != 1} {
exit 2
}
getcaptcha
} elseif [regexp {You may now go back and make your post} $state(body) ] {
puts SUCCESS
exit 0
} else {
puts $state(body)
exit 1
}
::http::cleanup $tok
}

proc getcaptcha {} {
.input delete 0 end
set tok [::http::geturl https://8ch.net/dnsbls_bypass.php]
upvar #0 $tok state
if {$state(status) ne "ok"} {
puts $state(staus)
exit 1
}
regexp {input class='captcha_cookie'.*value='([^']+)'} \
$state(body) - ::cookie;
regexp {image src=\"data:image/png;base64,([^\"]+)\"} \
$state(body) - img64;
image create photo img -data $img64
.img configure -image img
::http::cleanup $tok
}

package require Tk
label .img -text {Captcha Image}
button .submit -text Submit -command submit
entry .input
bind .input <Return> {.submit flash; .submit invoke}
button .close -text Close -command exit
bind . <Escape> {.close flash; .close invoke}
grid x .img -
grid x .input -
grid x .submit .close
focus .input
getcaptcha


 No.1042514>>1042519 >>1042599

>>1042511

>newfag types captcha in the correct case

lel

Using Tcl for human emulation is useful


 No.1042519>>1042574 >>1042599

>>1042514

srry ur so offend by me typin


 No.1042574>>1042599

>>1042519

> ur so offend

>offended

lel. No newfag. I was laughing because you took the time to make the captcha script but still didn't know you can type in any case & it werkz.

I guess they forgot to put it in your manual

obvious-hasbara/10 but your unit hasn't been here in a while so is expected to be a bit sloppy ;^)


 No.1042582

>>1042511

awesome


 No.1042599

>>1042519

>>1042514

>>1042574

you better be the same person and this better be ironic shitposting


 No.1042631

looks much harder than just doing it in the browser


 No.1042658

>>1042129 (OP)

>/tmp/captcha

>NOT USING MKTEMP

very nigger tier of you


 No.1042857

>>1042511

Very nice! Thanks.


 No.1056273

Why is there so much racism in this thread?


 No.1056417

Lots of shills in this thread.


 No.1056569

Wow. Just wow.


 No.1056816

Europeons need to burn in a tar-pit. Disgusting


 No.1057446

This isn't going to work. Try again.


 No.1057521

This is a Q Boomer psy-ops.




[Return][Go to top][Catalog][Screencap][Nerve Center][Cancer][Update] ( Scroll to new posts) ( Auto) 5
28 replies | 3 images | Page ???
[Post a Reply]
[ / / / / / / / / / / / / / ] [ dir / dempart / feet / hypno / jenny / komica / monarchy / vichan / vril ][ watchlist ]