Compare commits
No commits in common. "2d9de35adaa1d7fa7c0da2a883cabc731a76a011" and "db2c0afeaa5c36028d817b32550942b82ef17127" have entirely different histories.
2d9de35ada
...
db2c0afeaa
|
@ -1,15 +1,11 @@
|
||||||
# openclassroom pour entrainement et video
|
openclassroom pour entrainement et video
|
||||||
|
|
||||||
* Site internet pour ligne de commande [ici](https://ryanstutorials.net/)
|
|
||||||
|
|
||||||
## Ligne de commande
|
Site internet pour ligne de commande [ici](https://ryanstutorials.net/)
|
||||||
|
|
||||||
Creation ficher
|
**Ligne de commande**
|
||||||
|
|
||||||
```bash
|
|
||||||
touch "nom du file"
|
|
||||||
```
|
|
||||||
|
|
||||||
|
Creation ficher touch "nom du file"
|
||||||
\ : maniere de creer le nom d'un dossier sans qu'il en face plusieurs a cause des espaces
|
\ : maniere de creer le nom d'un dossier sans qu'il en face plusieurs a cause des espaces
|
||||||
|
|
||||||
Editeur de text 'nano' utilé pour la création de text
|
Editeur de text 'nano' utilé pour la création de text
|
||||||
|
@ -18,13 +14,7 @@ Editeur de text 'nano' utilé pour la création de text
|
||||||
commande file : determiner le type de ficher sait
|
commande file : determiner le type de ficher sait
|
||||||
Chercher le chemin d'un file : which "ficher en question"
|
Chercher le chemin d'un file : which "ficher en question"
|
||||||
|
|
||||||
pour renomer ficher:
|
pour renomer ficher : mv "ficher1 " ficher2"
|
||||||
|
|
||||||
```bash
|
|
||||||
mv "ficher1 " ficher2"
|
|
||||||
```
|
|
||||||
|
|
||||||
### wildcards
|
|
||||||
|
|
||||||
* - represents zero or more characters
|
* - represents zero or more characters
|
||||||
? - represents a single character
|
? - represents a single character
|
||||||
|
@ -36,17 +26,10 @@ touch Picture_ {00..99}.jpg
|
||||||
[Pp] pour avoir une liste avec P et p
|
[Pp] pour avoir une liste avec P et p
|
||||||
|
|
||||||
|
|
||||||
### Ajouter user
|
**Ajouter user**
|
||||||
|
|
||||||
As adding a user to the system is quite invasive, you need to have sufficient privilaged to do so.
|
|
||||||
This can be done eighter as *root* or as by prepending *sudo* to the command.
|
|
||||||
Sudo will execute the command as root.
|
|
||||||
All users you create will have a their *home* at /home/$USER.
|
|
||||||
|
|
||||||
```
|
|
||||||
sudo adduser marie
|
sudo adduser marie
|
||||||
ls /home
|
ls /home : voir les users
|
||||||
```
|
|
||||||
changer d'utilisateur via ligne de commande :^su 'nom'
|
changer d'utilisateur via ligne de commande :^su 'nom'
|
||||||
|
|
||||||
question : root?
|
question : root?
|
||||||
|
@ -70,6 +53,8 @@ sarahbis : sudo chown steve:steve mysecretfile pour donner le ownership a une au
|
||||||
|
|
||||||
Telecharger site via console : wget "site"
|
Telecharger site via console : wget "site"
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
Alias pour creer un nouveau raccourci
|
Alias pour creer un nouveau raccourci
|
||||||
Creer une nouvelle variable : nano .bashrc, #Own command
|
Creer une nouvelle variable : nano .bashrc, #Own command
|
||||||
exemple : alias ll="ls-l"
|
exemple : alias ll="ls-l"
|
||||||
|
|
17
Questions.md
17
Questions.md
|
@ -1,16 +1,7 @@
|
||||||
# Questions
|
Question?
|
||||||
|
|
||||||
## Regex?
|
regex?
|
||||||
|
Wildcards?
|
||||||
|
Var log msg?
|
||||||
|
|
||||||
Regex is short for regular expression.
|
|
||||||
[Wikipedia](https://en.wikipedia.org/wiki/Regular_expression) explains it better than me.
|
|
||||||
|
|
||||||
## Wildcards?
|
|
||||||
|
|
||||||
Wildcards are similar to regex but a lot simpler.
|
|
||||||
A quick [tutorial](https://linuxhint.com/bash_wildcard_tutorial/) explains it better than me.
|
|
||||||
|
|
||||||
## Var log msg?
|
|
||||||
|
|
||||||
The debian system administrator gives a good [overview](https://debian-handbook.info/browse/stable/sect.filesystem-hierarchy.html) of the directory structure of the linux OS.
|
|
||||||
|
|
||||||
|
|
|
@ -1,16 +0,0 @@
|
||||||
Reponse bandit
|
|
||||||
|
|
||||||
bandit 4 : cd inhere | file -- * | cat < -file07
|
|
||||||
|
|
||||||
bandit 5 : du -ab | grep 1033 | cat.maybehere07/.file02
|
|
||||||
|
|
||||||
bandit 6 :find /. -type f -group bandit6 -user bandit -size 33c | cat / ./var/lib/dpkg/info/bandit7.password
|
|
||||||
|
|
||||||
bandit 7 : cat Data.text | grep millionth cvX2JJa4CFALtqS87jk27qwqGhBM9plV
|
|
||||||
|
|
||||||
bandit 8 : sort data.txt | uniq -u code
|
|
||||||
UsvVyFSfZZWbi6wgC7dAFyFuR6jQQUhR
|
|
||||||
|
|
||||||
bandit 9 : strings data.txt | grep =
|
|
||||||
|
|
||||||
bandit 10 : IFukwKGsFW8MOq3IRFqrxE1hxTNEbUPR
|
|
|
@ -1,5 +1,3 @@
|
||||||
# Sites utiles
|
Sites utiles
|
||||||
|
|
||||||
[Ryan's tutorials](https://ryanstutorials.net/linuxtutorial/filters.php)
|
https://ryanstutorials.net/linuxtutorial/filters.php
|
||||||
[bandit](https://overthewire.org/wargames/bandit/bandit4.html) ssh wargame
|
|
||||||
[command line challenge](https://cmdchallenge.com/)
|
|
Loading…
Reference in New Issue