just another foolish blog
15.2.14
16.11.13
undefined reference to `yywrap' compiling PAM
2:22 PM
Posted by Eren Yağdıran
compile, debian, flex, install, linux, package, pam, problem, yywrap
No comments
If you get this error while compiling pam modules ,
be sure you have flex package as installed..
I was working on debian.
/home/eren/PAM/Linux-PAM-1.1.1/conf/pam_conv1/pam_conv_l.c:871: undefined reference to `yywrap'
collect2: error: ld returned 1 exit status
make[4]: *** [pam_conv1] Error 1
make[4]: Leaving directory `/home/eren/PAM/Linux-PAM-1.1.1/conf/pam_conv1'
make[3]: *** [all] Error 2
make[3]: Leaving directory `/home/eren/PAM/Linux-PAM-1.1.1/conf/pam_conv1'
make[2]: *** [all-recursive] Error 1
make[2]: Leaving directory `/home/eren/PAM/Linux-PAM-1.1.1/conf'
make[1]: *** [all-recursive] Error 1
make[1]: Leaving directory `/home/eren/PAM/Linux-PAM-1.1.1'
make: *** [all] Error 2
i fix this problem by installing flex package in debian repository.
apt-get install flex
i hope , it also works for you.
be sure you have flex package as installed..
I was working on debian.
/home/eren/PAM/Linux-PAM-1.1.1/conf/pam_conv1/pam_conv_l.c:871: undefined reference to `yywrap'
collect2: error: ld returned 1 exit status
make[4]: *** [pam_conv1] Error 1
make[4]: Leaving directory `/home/eren/PAM/Linux-PAM-1.1.1/conf/pam_conv1'
make[3]: *** [all] Error 2
make[3]: Leaving directory `/home/eren/PAM/Linux-PAM-1.1.1/conf/pam_conv1'
make[2]: *** [all-recursive] Error 1
make[2]: Leaving directory `/home/eren/PAM/Linux-PAM-1.1.1/conf'
make[1]: *** [all-recursive] Error 1
make[1]: Leaving directory `/home/eren/PAM/Linux-PAM-1.1.1'
make: *** [all] Error 2
i fix this problem by installing flex package in debian repository.
apt-get install flex
i hope , it also works for you.
14.11.13
Who am i ? [showterm]
1:38 PM
Posted by Eren Yağdıran
bash, embed, interactive, script, shell, showterm, website
No comments
Hello , i ve been testing showterm.io to embed interactive shell commands into blogposts.
http://showterm.io is perfect for embedding interactive shell commands into blogposts.
http://showterm.io is perfect for embedding interactive shell commands into blogposts.
24.8.13
[arch linux] Systemd-journald yüksek cpu kullanımı.
11:44 AM
Posted by Eren Yağdıran
arch, conf, Forward, hooks, journal, linux, shutdown, syslog, systemd, usage
No comments
Eğer böyle bir sorunla karşılaşır iseniz , ekrana kafa atmadan önce dediklerimi yapın
journalctl --disk-usage yapıp , file systemde yaratılan journalların büyüklüğüne bakın.Eğer gb'larca değilse bu sayfayı kapatın.
Eğer disk-usage çok fazlaysa ,
/etc/systemd/journald.conf dosyasından
SystemMaxUse=16M
ForwardToSyslog=no
olarak değiştirin.
birde initramfs'de shutdown hook olarak ekleyin ki systemd journal clean-up'ları kapatırken de yapsın.Bunun için
/etc/mkinitcpio.conf dosyasından
HOOKS satısına "shutdown" ekleyin.
son olarak da
mkinitcpio -p linux
yazarak da initramfs'i tekrar oluşturun
mevcut journallarınızdan kurtulmak için de
find /var/log/journal -name "*.journal~" -exec rm {} \;
yazdınız mı , alın size cillop gibi arch dağıtımı.
journalctl --disk-usage yapıp , file systemde yaratılan journalların büyüklüğüne bakın.Eğer gb'larca değilse bu sayfayı kapatın.
Eğer disk-usage çok fazlaysa ,
/etc/systemd/journald.conf dosyasından
SystemMaxUse=16M
ForwardToSyslog=no
olarak değiştirin.
birde initramfs'de shutdown hook olarak ekleyin ki systemd journal clean-up'ları kapatırken de yapsın.Bunun için
/etc/mkinitcpio.conf dosyasından
HOOKS satısına "shutdown" ekleyin.
son olarak da
mkinitcpio -p linux
yazarak da initramfs'i tekrar oluşturun
mevcut journallarınızdan kurtulmak için de
find /var/log/journal -name "*.journal~" -exec rm {} \;
yazdınız mı , alın size cillop gibi arch dağıtımı.
25.10.12
Even Tree problem & my solution
You are given a tree (a simple connected graph with no cycles).You have to remove as many edges from the tree as possible to obtain a forest with the condition that : Each connected component of the forest contains even number of vertices
Your task is to calculate the number of removed edges in such a forest.
Input:
The first line of input contains two integers N and M. N is the number of vertices and M is the number of edges. 2 <= N <= 100.
Next M lines contains two integers ui and vi which specifies an edge of the tree. (1-based index)
Output:
Print a single integer which is the answer
Input:
The first line of input contains two integers N and M. N is the number of vertices and M is the number of edges. 2 <= N <= 100.
Next M lines contains two integers ui and vi which specifies an edge of the tree. (1-based index)
Output:
Print a single integer which is the answer
Sample Input
10 9
2 1
3 1
4 3
5 2
6 1
7 2
8 6
9 8
10 8
Sample Output :
2
Explanation : On removing the edges (1, 3) and (1, 6), we can get the desired result.
Original tree:

Decomposed tree:


Decomposed tree:

Note: The tree in the input will be such that it can always be decomposed into components containing even number of nodes.
My solution is on pastebin - clickhere
18.10.12
Lets scape Google
i just need to have couple of urls in google results
so instead of writing a pure http client for spoofing google , i write some junk of js files to fetch urls from google , without getting banned :)
I used firefox and greasemonkey plugin.
Basically , what this script does that ;
Check out my script here
so instead of writing a pure http client for spoofing google , i write some junk of js files to fetch urls from google , without getting banned :)
I used firefox and greasemonkey plugin.
Basically , what this script does that ;
- Wait until google ajax request is loaded
- parse the body content to obtaion urls by using regular expressions
- after those expressions are evaluaded , i send those url to external website by using GET request
- After sending is completed , script generates a fake next click event that is for fetching next page.
- And again to step 1 until all results are finished
- lastly , modify the gonder function in order to adapt your needs
Check out my script here
3.10.12
Mdk CrackME Çözümü & Keygen Yazımı
6:19 AM
Posted by Eren Yağdıran
assembly, c++, call, crack, crackme, group, keygen, mdk, mfc, stack, x86
No comments
http://mdkgroup.com/forum/viewtopic.php?p=4455
adresinde yayınlandığı üzere , mdk forumlarına giriş için bir crackme kırılmasını istemektedir.
Şimdi crackme 'yi indirelim ve olly debug adlı programda crackme'yi açalım.
OllyDebug adlı programda göreceğimiz üzere , 00401568 bizim entry pointimiz.
Şimdi Run edelim , user ve seriali sallayalım
0040132A 'ya bir break point koyalım ve calıştıralım
0x0040132A 'ya bir bakalım , burdaki kod username'imiz olan m00dy'yi PUSH layıp call stack'e atıyor ve CALL 00401050 'deki fonksiyona parametre olarak göndermiş oluyor.
şimdi 2 kez f8'e basalım ve eax registerindeki deger => 0xf26DA640
bu kullanıcı adımızı kullanarak olusturan bir değer ve büyük ihtimalle serial' algoritmasında kullanılcagını düşünüyoruz :)
şimdi biraz daha alta iniyoruz ve 004010d0 adresinde baska bir fonksiyon var
0040133E adresine bakarsanız orda TEST EAX,EAX oldugunu goreceksiniz yani uzerindeki fonksiyondan donen degere gore "Invalid Serial" yada "Welcome to Deck ;) " yazacak :)
şimdi 0040133E adresinin içine bakalım ve algoritmayı cozelim
0x00401255 bir breakpoint koyalım
Dolayısı ile şifremiz
CPU Stack Address Value ASCII Comments
0012F9F4 0012F9FD ASCII "9D2F7F20-9D4AD6B8"
sağ alttan bakıcak olursak , şifremiz neymiş 9D2F7F20-9D4AD6B8 :) nice
şimdi keygen kodlarını ekleyip blogpostuma , bu yazıyı da bitireyim
Keygen Download ( C++ MFC 'de yazıldı , redistribution libraryleri yuklemeniz gerekebilir)
İlk yazdıgım keygenimin ekran görüntüsü :)
adresinde yayınlandığı üzere , mdk forumlarına giriş için bir crackme kırılmasını istemektedir.
Şimdi crackme 'yi indirelim ve olly debug adlı programda crackme'yi açalım.
OllyDebug adlı programda göreceğimiz üzere , 00401568 bizim entry pointimiz.
Şimdi Run edelim , user ve seriali sallayalım
0040132A 'ya bir break point koyalım ve calıştıralım
şimdi 2 kez f8'e basalım ve eax registerindeki deger => 0xf26DA640
bu kullanıcı adımızı kullanarak olusturan bir değer ve büyük ihtimalle serial' algoritmasında kullanılcagını düşünüyoruz :)
şimdi biraz daha alta iniyoruz ve 004010d0 adresinde baska bir fonksiyon var
0040133E adresine bakarsanız orda TEST EAX,EAX oldugunu goreceksiniz yani uzerindeki fonksiyondan donen degere gore "Invalid Serial" yada "Welcome to Deck ;) " yazacak :)
şimdi 0040133E adresinin içine bakalım ve algoritmayı cozelim
0x00401255 bir breakpoint koyalım
Dolayısı ile şifremiz
CPU Stack Address Value ASCII Comments
0012F9F4 0012F9FD ASCII "9D2F7F20-9D4AD6B8"
sağ alttan bakıcak olursak , şifremiz neymiş 9D2F7F20-9D4AD6B8 :) nice
şimdi keygen kodlarını ekleyip blogpostuma , bu yazıyı da bitireyim
Keygen Download ( C++ MFC 'de yazıldı , redistribution libraryleri yuklemeniz gerekebilir)
İlk yazdıgım keygenimin ekran görüntüsü :)