Twitter

News: FASMW64 with more examples.

The FASM come with great examples. If you get a look on this topic, you will see the news about FASM.
The news are:
[FASMW64\FASMW32.EXE] – 32bit asm development
[FASMW64\FASMW64.EXE] – 64bit asm development
[FASMW64\DLL] – 32bit DLL’s required by most programs
[FASMW64\DLL64] – 64bit DLL’s requred by some programs
[FASMW64\fasmw16935] – Original FasmW package un-modified
[FASMW64\Resources] – audio/image/etc.. required by some programs
[FASMW64\SOURCE] – Changes to the source code made by me (currently only fasmw.asm)
[FASMW64\V7 Examples 32bit] – 32bit example code, includes: DX7, DX8, DX9, DX10, Windows (use FASMW32.EXE to compile)
[FASMW64\V7 Examples 64bit] – 64bit example code, includes: DX9, DX10, Windows (use FASMW64.EXE to comile)
[FASMW64\V7INCLUDE32 32bit] – Vista/Win7 include files and api’s
[FASMW64\V7SHELLS32 32bit] – Window Shells
[FASMW64\V7INCLUDE64 64bit] – Vista/Win7 include files and api’s
[FASMW64\V7SHELLS64 64bit] – Window Shells

The FASMW is a great way to learn and deal with assembly language.
The forum has many users to help you.
The goal to understand assembly language is to learn the basic and then to start to put questions.

SymPy python module with Python 3.4.1 .

SymPy is a Python library for symbolic mathematics.
This module is a computer algebra system (CAS) written in the Python programming language.
A large can be found on this blog aggregator at planet.sympy.org.
First, You need to install it using pip3.4.

C:\Python34\Scripts>pip3.4.exe install sympy
Collecting sympy
  Downloading sympy-0.7.6.tar.gz (6.4MB)
    100% |################################| 6.4MB 35kB/s
Building wheels for collected packages: sympy
...
Successfully built sympy
Installing collected packages: sympy
Successfully installed sympy-0.7.6

For a short introduction into SymPy python module I will show you the printing features.
The most common printers available in SymPy are:

  • str
  • repr
  • ASCII pretty printer
  • Unicode pretty printer
  • LaTeX
  • MathML
  • Dot

Let’s test it this first example:

C:\Python34>python
Python 3.4.1 (v3.4.1:c0e311e010fc, May 18 2014, 10:45:13) [MSC v.1600 64 bit (AMD64)] on win32
Type "help", "copyright", "credits" or "license" for more information.
>>> from sympy import *
>>> x,y,z = symbols('x y z')
>>> Integral(sqrt(1+1/x),x)
Integral(sqrt(1 + 1/x), x)
>>> init_session(quiet=True)
Python console for SymPy 0.7.6 (Python 3.4.1-64-bit) (ground types: python)

>>> Integral(sqrt(1+1/x),x)
  /
 |
 |     _______
 |    /     1
 |   /  1 + -  dx
 | \/       x
 |
/
>>>

How to print one matrix :

>>> x, y, z = symbols('x, y, z')
>>> init_session(quiet=True)
Python console for SymPy 0.7.6 (Python 3.4.1-64-bit) (ground types: python)

>>> mat = Matrix([x*y, 1,0,3,-2, sin(z)])
>>> mat
[ x*y  ]
[      ]
[  1   ]
[      ]
[  0   ]
[      ]
[  3   ]
[      ]
[  -2  ]
[      ]
[sin(z)]
>>>

Next example come with this issue: equations can be solved with SymPy python module.

>>> solve(x*x+x+2)
         ___            ___
   1   \/ 7 *I    1   \/ 7 *I
[- - - -------, - - + -------]
   2      2       2      2
>>> solve(Eq(x*x+x+2))
         ___            ___
   1   \/ 7 *I    1   \/ 7 *I
[- - - -------, - - + -------]
   2      2       2      2
>>> solve(Eq(x*x+2*x+4))
        ___           ___
[-1 - \/ 3 *I, -1 + \/ 3 *I]
>>> solve(x*x+2*x+4)
        ___           ___
[-1 - \/ 3 *I, -1 + \/ 3 *I]
>>>

Pillow python module with Python 3.4.1 .

Pillow python module is the python PIL fork created by Alex Clark and Contributors.
As you know the PIL python module is the Python Imaging Library by Fredrik Lundh and Contributors.
I used Python 3.4 version with pip to install and upgrade the Pillow 2.8.1 python module.
The Pillow module version >= 2.0.0 supports Python versions 2.6, 2.7, 3.2, 3.3, 3.4 and no longer supports “import _imaging”. Please use “from PIL.Image import core as _imaging” instead.
Pillow and PIL cannot co-exist in the same environment and you nned to uninstall PIL and after install the Pillow python module.

C:\Python34\Scripts>pip3.4.exe install pillow
Requirement already satisfied (use --upgrade to upgrade): pillow in c:\python34\lib\site-packages

C:\Python34\Scripts>pip3.4.exe install pillow --upgrade
Collecting pillow
  Downloading Pillow-2.9.0-cp34-none-win_amd64.whl (1.3MB)
    100% |################################| 1.3MB 98kB/s
Installing collected packages: pillow
  Found existing installation: Pillow 2.8.1
    Uninstalling Pillow-2.8.1:
      Successfully uninstalled Pillow-2.8.1
Successfully installed pillow-2.9.0

Now you need to use PIL insead the Pillow. Let see:

C:\Python34\Scripts>cd ..
C:\Python34>python
Python 3.4.1 (v3.4.1:c0e311e010fc, May 18 2014, 10:45:13) [MSC v.1600 64 bit (AMD64)] on win32
Type "help", "copyright", "credits" or "license" for more information.
>>> import PIL
>>> from PIL import *
>>> dir(PIL)
['PILLOW_VERSION', 'VERSION', '__builtins__', '__cached__', '__doc__', '__file__', '__loader__', '__name__', '__package__', '__path__', '__spec__', '_plugins']
>>> print(PIL.VERSION)
1.1.7
>>> print(PIL.PILLOW_VERSION)
2.9.0
>>>

News: about Kali Linux 2.0 with VirtualBox.

Few days ago the team development has released the new Kali Linux 2.0 version.
You can download this distro from kali download page using ISO or torrent files. If you want to download it fast , then use torrent file.
The Kali Linux project it’s know like a strong distro with many features.
It’s based on Debian Jessie with a new 4.0 kernel and support for a variety of Desktop Environments (gnome, kde, xfce, mate, e17, lxde, i3wm).
The offensive security website wrote many articles about Kali Linux and this will help you to understand this distro.
One short video about Kali Linux:

I test it this distro with Virtual Box version 4.3.30 and working well with 512 Ram and 8 Gb virtual drive.
kali_linux_virtual_001

The haralyzer python module.

The HAR file is an open file format for archiving HTTP packets.
You can find a lot of tools available to analyse, visualize HAR files.
Today I will show you how to use haralyzer python module to show infos about your website.
This python module contains two classes for analyzing web pages based on a HAR file.
I install this python module using pip3.4 under Python 3.4.1 version.

C:\Python34\Scripts\pip3.4.exe install haralyzer
Collecting haralyzer
Using cached haralyzer-1.4.3.tar.gz
Collecting cached-property (from haralyzer)
Using cached cached_property-1.2.0-py2.py3-none-any.whl
Requirement already satisfied (use --upgrade to upgrade): numpy in c:\python34\lib\site-packages (from haralyzer)
...
Building wheels for collected packages: haralyzer
Running setup.py bdist_wheel for haralyzer
Stored in directory:
...
Successfully built haralyzer
Installing collected packages: cached-property, haralyzer
Successfully installed cached-property-1.2.0 haralyzer-1.4.3

I used one online free tool to create a test.har file.
I put this file under Python3.4 folder and I test it.
The script I used is this:

import json
from haralyzer import HarParser, HarPage

with open('test_dev.har', 'r') as f:
    har_parser = HarParser(json.loads(f.read()))

print (har_parser.browser)
# {u'name': u'Firefox', u'version': u'25.0.1'}

for page in har_parser.pages:
    assert isinstance(page, HarPage)

And this is the output of this script :

C:\Python34>python.exe har_test.py
{'version': '39.0.3', 'name': 'Firefox'}