Table des matières
- 2026:
- 2025:
12 billet(s) pour novembre 2026
| Notes conversion JSON YAML | 2026/11/13 11:16 | Jean-Baptiste |
| Git commit perdu | 2026/11/12 18:16 | Jean-Baptiste |
| Notes mojo lang | 2026/11/11 20:34 | Jean-Baptiste |
| Notes rust lang compilation | 2026/11/11 18:35 | Jean-Baptiste |
| Mémoire VSIZE VMSIZE SEGV lang C | 2026/11/11 15:59 | Jean-Baptiste |
| Ansible-navigator utilisation de ansible-vault | 2026/11/06 11:33 | Jean-Baptiste |
| Err Ansible - Module result deserialization failed No start of json char found | 2026/11/06 09:09 | Jean-Baptiste |
| Script Python conversion JSON vers CSV | 2026/11/06 08:14 | Jean-Baptiste |
| Filter Incoming IPv4 Packets Containing IP Options - cve-2026-98432 mitigation - Kernel TCP Use-After-Free | 2026/11/04 21:04 | Jean-Baptiste |
| Notes ZFS | 2026/11/03 18:04 | Jean-Baptiste |
| Diff image container | 2026/11/03 16:30 | Jean-Baptiste |
| Notes processus multi-thread | 2026/11/03 10:59 | Jean-Baptiste |
Notes YubiKey FIDO PIN
$ ykman fido access verify-pin Enter your PIN: ERROR: PIN verification failed: CTAP error: 0x32 - PIN_BLOCKED. $ ykman fido info AAGUID: 1fc0579f-8113-47ea-b116-bb5a8db9203b PIN: Blocked Minimum PIN length: 4 $ ykman fido reset WARNING! This will delete all FIDO credentials, including FIDO U2F credentials, and restore factory settings. Proceed? [y/N]: y Remove your YubiKey from the USB port. Re-insert your YubiKey now... Touch the YubiKey to confirm. Reset in progress, DO NOT REMOVE YOUR YUBIKEY! FIDO application data reset. $ ykman fido access change-pin Enter your new PIN: Repeat for confirmation: FIDO PIN updated.
Tester les flux réseaux UDP
Voir aussi remplacer_telnet_nc_sous_linux
telnet c'est pratique, mais ça ne marche que pour TCP
!! UDP n'est pas un protocole en mode connecté
Netcat est votre ami
$ nc -zvu 127.0.0.1 1-65535 Connection to 127.0.0.1 111 port [udp/*] succeeded! Connection to 127.0.0.1 161 port [udp/*] succeeded! Connection to 127.0.0.1 897 port [udp/*] succeeded! Connection to 127.0.0.1 1900 port [udp/*] succeeded! Connection to 127.0.0.1 2086 port [udp/*] succeeded! Connection to 127.0.0.1 5353 port [udp/*] succeeded! Connection to 127.0.0.1 32964 port [udp/*] succeeded! Connection to 127.0.0.1 34578 port [udp/*] succeeded! Connection to 127.0.0.1 37878 port [udp/*] succeeded!
$ nc -uvz serveur 1-162 serveur [172.17.39.87] 162 (snmp-trap) open serveur [172.17.39.87] 123 (ntp) open serveur [172.17.39.87] 67 (bootps) open
Sinon il existe Nmap
Netcat - bind binding NIC
nc -lnp 3306 192.168.200.62
$ ss -tln | grep 3306 LISTEN 0 1 192.168.200.62:3306 0.0.0.0:*
unixsock Unix domain sockets
echo -e "GET /containers/omsa82-snmp/stats HTTP/1.0\r\n" | nc -U /var/run/docker.sock
Autres
Bande passante :
- bwm-ng
- iperf
cat /sys/class/net/eth0/statistics/tx_bytes
# awk '/^Udp:/ { print $5}' /proc/1565/net/snmp
OutDatagrams
208064
Info
# cat /sys/class/net/eth0/duplex full
# cat /sys/class/net/eth0/speed 1000
# cat /sys/class/net/eth0/address 08:00:27:56:10:6a
Notes gitlab - certificats CA
cp -p *.crt /usr/local/share/ca-certificates/ update-ca-certificates
# curl -I https://arty.acme.local curl: (60) SSL certificate problem: unable to get local issuer certificate More details here: https://curl.se/docs/sslcerts.html curl failed to verify the legitimacy of the server and therefore could not establish a secure connection to it. To learn more about this situation and how to fix it, please visit the web page mentioned above.
# curl --cacert /usr/local/share/ca-certificates/acme-subca1.crt -I https://arty.acme.local HTTP/1.1 200 OK ...
# wget https://arty.acme.local --2026-06-11 11:41:00-- https://arty.acme.local/ Resolving arty.acme.local (arty.acme.local)... 10.245.208.69, 10.245.208.36 Connecting to arty.acme.local (arty.acme.local)|10.245.208.69|:443... connected. HTTP request sent, awaiting response... 200 OK Length: 23381 (23K) [text/html] Saving to: ‘index.html’ index.html 100%[====================================================================================================================>] 22.83K --.-KB/s in 0.02s 2026-06-11 11:41:00 (1.00 MB/s) - ‘index.html’ saved [23381/23381]
# which curl /opt/gitlab/embedded/bin/curl
# cat /opt/gitlab/etc/gitaly/env/SSL_CERT_DIR ; echo /opt/gitlab/embedded/ssl/certs/ # cat /opt/gitlab/embedded/ssl/certs/README This directory is managed by omnibus-gitlab. Any file placed in this directory will be ignored . Place certificates in /etc/gitlab/trusted-certs. # ls -l /etc/gitlab/trusted-certs total 0
Solution
cp -p /usr/local/share/ca-certificates/* /etc/gitlab/trusted-certs/
Redémarrer Gitlab
Notes Gitlab-ci pipeline - API
Voir :
Exemple 1 - avec Access Token ou Personnal Access tokens
Avec Access Token (associé au projet)
- Aller dans le projet - puis : Settings / Access tokens
- Attention : par défaut les Access Tokens ont une date d'expiration
Avec Personnal Access tokens (associé au compte utilisateur)
- Profile / Edit profile / Access Token / Personal Access Tokens
- Attention : par défaut les Personal Access Tokens ont une date d'expiration
Launch pipeline with API call - with Private / Personal access tokens
curl --request POST \ --header "PRIVATE-TOKEN: saltxx-8888888888" \ --header "Content-Type: application/json" \ --data '{ "ref": "master", "variables": [ {"key": "VAR1", "value": "plop"}, {"key": "VAR2", "value": "plop"}, {"key": "VAR3", "value": "plop"}, {"key": "VAR4", "value": ""} ] }' \ --url "${CI_API_V4_URL}/projects/100/pipeline"
Notes
CI_API_V4_URL est une variable magique dont la valeur est de la forme : http://gitlab.acme.local/api/v4
Dans notre cas la variable ref correspond au nom de la branche
Exemple 2 - Avec Trigger Tokens
Voir :
Voir aussi :
Aller dans le projet, puis Settings/ CI/CD / Pipeline trigger tokens
Trigger pipeline with the API / Pass CI/CD variables in the API call
curl --request POST \ --form token=glptt-99999999999999 \ --form ref=master \ --form "variables[VAR1]=plop" \ --form "variables[VAR2]=plop" \ --form "variables[VAR3]=plop" \ --form "variables[VAR4]=plop" \ "${CI_API_V4_URL}/projects/100/trigger/pipeline"
Avec Ansible
.gitlab-ci.yml
launch: tags: # - gitlab-runner-sh-001 - gitlab-runner-docker-001 image: registry.acme.local/repository/local-docker/ansible-builder:0.0.4 stage: build script: ansible-playbook play-launch-ci.yml -e url="${CI_API_V4_URL}" -e token="${TRIGGER_TOKEN}"
play-launch-ci.yml
#! /usr/bin/env ansible-playbook --- - name: Launch CI gather_facts: false hosts: localhost vars: branch: "{{ lookup('env', 'BRANCH') }}" line: "{{ lookup('env', 'LINE') }}" kind: "{{ lookup('env', 'KIND') }}" tasks: - name: Assert check environment vars are correctly defined ansible.builtin.assert: that: - url is defined and url != '' - token is defined and token != '' - branch is defined and branch != '' - line is defined and line != '' - kind is defined and kind != '' msg: "Env var must be defined" - name: Call API # no_log: true register: reg_uri until: reg_uri.status == 201 retries: 3 delay: 5 # Every 5 seconds ansible.builtin.uri: url: "{{ url }}/projects/100/trigger/pipeline" # validate_certs: false status_code: 201 follow_redirects: none method: POST body_format: json headers: Content-Type: "application/json" body: | { "ref": "main", "token": "{{ token }}", "variables": { "BRANCH": "{{ branch }}", "KIND": "{{ kind }}", "LINE": "{{ line }}" } }
Autres
000-colo-switch:prod: stage: deploy variables: PROJECT: "projectname" rules: # whether to include the job in the pipeline - if: $CI_PIPELINE_SOURCE == "trigger" when: always - when: never
Source: https://forum.gitlab.com/t/triggering-a-specific-job-of-the-pipeline-via-api/42397/2
Notes API - REST - outils
Voir :
Outils API
- Advanced REST
- HttpRequester
- RESTClient
- REST-assured
- hoppscotch
- FastAPI (Python)
- Tuto
Voir : https://en.wikipedia.org/wiki/Microservices#Criticism_and_concerns
Low-code :
GUI
- SoapUI
CLI like curl
- HTTPie
Serveur proxy MITM
- Paros
- mitmproxy
Extension Firefox / Chromium :
- Postman ?
- Live HTTP headers
Dev
OpenAPI / Swagger
- hippie-swagger
Autres :
- AsyncAPI & AsyncAPI Generator
API Gateway
- WSO2
