‏הצגת רשומות עם תוויות CheatSheet. הצג את כל הרשומות
VI הוא עורך טקסט נפוץ בסביבת יוניקס, פירוש שמו הוא Visual.
להלן הפקודות שבעזרתן ניתן לעבוד עם העורך:


vi newfile - יצירת קובץ חדש
:esc + q + Enter - יציאה מקובץ ללא שינויים
esc + :w - שמירה של השינויים
esc + :x - שמירה ויציאה מהקובץ
esc + dd - מחיקת שורה שלמה
esc + 2dd - מחיקת 2 שורות
:q - יציאה מקובץ ללא שינויים
:q! - יציאה מקובץ ללא שמירה
insert או i - מצב כתיבה
esc $ - קופץ לסוף שורה
esc ^ - קופץ לתחילת שורה
shift + p - מעתיק שורה
esc + o - מוסיף שורה עליונה
esc :/string - חיפוש בתוך המסמך
esc dw - מחיקת מילה
esc + u - ביטול פעולה
esc + yy - העתק שורה
esc + p - הדבק שורה

כיצד לבחון את רשת האינטרנט שברשותך?

לצורך הבדיקה נוריד ונתקין את סט הכלים של aircrack-ng.
כולל בתוכו:
* airmon-ng
* airodump-ng
* aireplay-ng
* aircrack-ng


הבדיקה נעשתה באמצעות ראוטר שנמצא בבעלותי, חשוב להבהיר שתקיפת רשתות אלחוטיות שלא בבעלותך מהווה עבירה על החוק. אחזור ואדגיש כי החומר המוצג באתר הינו לצורכי הוראה, לימוד ומחקר בלבד! כל שימוש אחר במידע הינו באחריות המשתמש!

פקודות בסיסיות MySQL:


mysql -u root -p - התחברות אל מסד הנתונים משתמש רוט
quit - יציאה מהשירות
show databases; - הצגת מסדי הנתונים הקיימים
create database supersecret; - supersecret יצירת מסד נתונים בשם
use information_schema - information_schema מעבר אל מסד הנתונים
show tables; - הצגת טבלאות

יצירת טבלה חדשה עם מספר עמודות (לכל עמודה יש להגדיר מראש את סוג הקלט):
mysql> create table employees (
    -> id INTEGER,
    -> name TEXT,
    -> age INTEGER
    -> );
Query OK, 0 rows affected (0.01 sec)

הצגת מידע אודות העמודות המופיעות בטבלה:
mysql> describe employees;
+-------+---------+------+-----+---------+-------+
| Field | Type    | Null | Key | Default | Extra |
+-------+---------+------+-----+---------+-------+
| id    | int(11) | YES  |     | NULL    |       |
| name  | text    | YES  |     | NULL    |       |
| age   | int(11) | YES  |     | NULL    |       |
+-------+---------+------+-----+---------+-------+
3 rows in set (0.00 sec)

הכנסת נתונים אל טבלה:
mysql> insert into employees (id, name, age)
    -> values (1, 'Haim Levanon', 42);
Query OK, 1 row affected (0.00 sec)

הצגת נתונים מטבלה:
mysql> select * from employees;
+------+---------------+------+
| id   | name          | age  |
+------+---------------+------+
|    1 | Haim Levanon  |   42 |
|    2 | Itzhak Shamir |   29 |
+------+---------------+------+
2 rows in set (0.00 sec)

הוספתי עוד מספר עובדים:
mysql> select * from employees;
+------+------------------+------+
| id   | name             | age  |
+------+------------------+------+
|    1 | Haim Levanon     |   42 |
|    2 | Itzhak Shamir    |   29 |
|    3 | Damba Rubma      |   42 |
|    4 | Runda Juakim     |   49 |
|    5 | Marta Cohen      |   29 |
|    6 | Kalev Ben Yefune |   35 |
+------+------------------+------+
6 rows in set (0.00 sec)
הצגת כל העובדים שגילם 29:
mysql> select * from employees where age = 29;
+------+---------------+------+
| id   | name          | age  |
+------+---------------+------+
|    2 | Itzhak Shamir |   29 |
|    5 | Marta Cohen   |   29 |
+------+---------------+------+
2 rows in set (0.00 sec)

הצגת שמות כל העובדים:
mysql> select name from employees;
+------------------+
| name             |
+------------------+
| Haim Levanon     |
| Itzhak Shamir    |
| Damba Rubma      |
| Runda Juakim     |
| Marta Cohen      |
| Kalev Ben Yefune |
+------------------+
6 rows in set (0.00 sec)

עדכון נתונים בטבלה:
mysql> select * from employees;
+------+------------------+------+
| id   | name             | age  |
+------+------------------+------+
|    1 | Haim Levanon     |   42 |
|    2 | Itzhak Shamir    |   29 |
|    3 | Damba Rubma      |   42 |
|    4 | Runda Juakim     |   49 |
|    5 | Marta Cohen      |   29 |
|    6 | Kalev Ben Yefune |   35 |
+------+------------------+------+
6 rows in set (0.00 sec)

mysql> update employees
    -> set age = 29
    -> where id = 6;
Query OK, 1 row affected (0.01 sec)
Rows matched: 1  Changed: 1  Warnings: 0

נבדוק האם השינויים התעדכנו:
mysql> select * from employees where id = 6;
+------+------------------+------+
| id   | name             | age  |
+------+------------------+------+
|    6 | Kalev Ben Yefune |   29 |
+------+------------------+------+
1 row in set (0.00 sec)

הוספת עמודה חדשה לטבלה:
mysql> alter table employees add column
    -> phone integer;
Query OK, 6 rows affected (0.01 sec)
Records: 6  Duplicates: 0  Warnings: 0

mysql> select * from employees;
+------+------------------+------+-------+
| id   | name             | age  | phone |
+------+------------------+------+-------+
|    1 | Haim Levanon     |   42 |  NULL |
|    2 | Itzhak Shamir    |   29 |  NULL |
|    3 | Damba Rubma      |   42 |  NULL |
|    4 | Runda Juakim     |   49 |  NULL |
|    5 | Marta Cohen      |   29 |  NULL |
|    6 | Kalev Ben Yefune |   29 |  NULL |
+------+------------------+------+-------+
6 rows in set (0.00 sec)

מחיקת נתונים מתוך הטבלה:
mysql> DELETE FROM employees where id=3;
Query OK, 1 row affected (0.01 sec)

mysql> select * from employees;
+------+------------------+------+-------+
| id   | name             | age  | phone |
+------+------------------+------+-------+
|    1 | Haim Levanon     |   42 |  NULL |
|    2 | Itzhak Shamir    |   29 |  NULL |
|    4 | Runda Juakim     |   49 |  NULL |
|    5 | Marta Cohen      |   29 |  NULL |
|    6 | Kalev Ben Yefune |   29 |  NULL |
+------+------------------+------+-------+
5 rows in set (0.01 sec)

מחיקת עמודות:
mysql> alter table employees drop phone;
Query OK, 5 rows affected (0.00 sec)
Records: 5  Duplicates: 0  Warnings: 0

mysql> select * from employees;
+------+------------------+------+
| id   | name             | age  |
+------+------------------+------+
|    1 | Haim Levanon     |   42 |
|    2 | Itzhak Shamir    |   29 |
|    4 | Runda Juakim     |   49 |
|    5 | Marta Cohen      |   29 |
|    6 | Kalev Ben Yefune |   29 |
+------+------------------+------+
5 rows in set (0.00 sec)


פקודות בסיסיות Powershell:

* ניתן להשתמש במקש ה-Tab להשלמת פקודות אוטומטי.
Get - הצגת מידע.
Set - שינוי והגדרת נתונים.
Format - הצגת נתונים.
Out - קביעת יעד של הפלט.