Tag: create

Backtrack, Cracking, Wordlist

How to make a wordlist in BackTrack

Crunch is a wordlist generator where you can specify a standard character set or a character set you specify. crunch can generate all possible combinations and permutations. Features crunch generates wordlists in both combination and permutation ways it can breakup output by number of lines or file size now has resume support pattern now supports …

PHP

Create JSON data in PHP

json_encode Code: $data = array (’id’=>1, ‘firstname’=>’george’, ‘lastname’=>’karpouzas’, ’emails’=>array(’abcd@gmail.com’,’abcd@yahoo.com’));   echo json_encode($data);$data = array (‘id’=>1, ‘firstname’=>’george’, ‘lastname’=>’karpouzas’, ’emails’=>array(‘abcd@gmail.com’,’abcd@yahoo.com’)); echo json_encode($data); Output: {“id”:1,”firstname”:”george”,”lastname”:”karpouzas”,”emails”:[“abcd@gmail.com”,”abcd@yahoo.com”]}

C#, Microsoft Windows

Dynamically create textbox and label at runtime – C#

Let’s see how we can create dynamically a panel and add two controls into it, a label and a textbox. Panel panel = new Panel(); panel.Location = new System.Drawing.Point(30, 20); panel.Name = "panel1"; panel.AutoSize = true; panel.Size = new System.Drawing.Size(230, 20);   Label l = new Label(); l.AutoSize = true; l.Location = new System.Drawing.Point(3, 5); …

Python

Create images thumbnails with Python

import glob import Image dir="/home/username/Pictures/"   for infile in glob.glob(dir+"*.jpg"): imgfile=infile[(infile.rfind("/")+1):] if infile[0:2] == "thumb_": continue try: img = Image.open(infile) img.thumbnail((128, 128), Image.ANTIALIAS) img.save(dir + "thumb_" + imgfile, "JPEG") except IOError: img=Noneimport glob import Image dir="/home/username/Pictures/" for infile in glob.glob(dir+"*.jpg"): imgfile=infile[(infile.rfind("/")+1):] if infile[0:2] == "thumb_": continue try: img = Image.open(infile) img.thumbnail((128, 128), Image.ANTIALIAS) img.save(dir + …

Linux, Subversion

How to properly create a svn tag from trunk

Create svn tag from trunk svn + ssh svn copy svn+ssh://username@server.com/myproj/trunk svn+ssh://username@server.com/myproj/tags/1.0 -m "Release 1.0"svn copy svn+ssh://username@server.com/myproj/trunk svn+ssh://username@server.com/myproj/tags/1.0 -m "Release 1.0" svn + http svn copy http://svn.server.com/myproj/trunk http://svn.server.com/myproj/tags/1.0 -m "Release 1.0"svn copy http://svn.server.com/myproj/trunk http://svn.server.com/myproj/tags/1.0 -m "Release 1.0"

Java

Create JSON data in Java

1. Download json-simple library (.jar file) from here. 2. Add a reference to the json-simple jar file. 3. Import package org.json.simple.JSONObject 4. Write your code: JSONObject jsonobj = new JSONObject(); jsonobj.put("city", "Athens"); jsonobj.put("country", "Greece"); System.out.println(jsonobj.toString());JSONObject jsonobj = new JSONObject(); jsonobj.put("city", "Athens"); jsonobj.put("country", "Greece"); System.out.println(jsonobj.toString());

C, Linux

Create QR codes with c

Library To create QR codes we are going to use open source library libqrencode. Installation I you are in Ubuntu install libqrencode by issuing the following command: sudo apt-get install libqrencode libqrencode-devsudo apt-get install libqrencode libqrencode-dev Source code #include <stdio.h> #include <qrencode.h> #include <errno.h>   int main(){ QRcode *qrcode; qrcode = QRcode_encodeString("http://webnetsoft.gr", 4, QR_ECLEVEL_H, QR_MODE_8, …

Multimedia, Ubuntu

Create your own online radio stream in Ubuntu

Installation sudo apt-get install icecast2sudo apt-get install icecast2 sudo apt-get install ices2sudo apt-get install ices2 Ices2 installation ask you to join DecNet choose the third choise to skip configuration. Icecast Configuration Open a terminal window and issue the following command: sudo gedit /etc/icecast2/icecast.xmlsudo gedit /etc/icecast2/icecast.xml   We are going to change the source and the …