Aller au contenu

Un question sur les droits d'accès a une commande Linux


Gecko64

Sujets conseillés

Bonjour le peuple ^^

Voilà, je viens pour vous faire part de ma question du jour :P

J'ai depuis peu un RPS chez OVH sur lequel je veux mettre une page phpsysinfo.

Pour ceux qui ne savent pas ce que c'est, c'est une page pouvant donner diverses informations sur votre système dont notamment sur le réseau.

Si je parle du réseau, c'est parce que bien sur, c'est avec lui que j'ai un souci...

En fait, le phpsysinfo a besoin d'utiliser ifconfig pour extraire certaines informations dont il a besoin et il se fait que sur une distribution Debian Lenny comme j'ai a la maison, en simple utilisateur, il m'est possible de faire /sbin/ifconfig pour faire fonctionner cette commande.

Donc mon utilisateur www-data du même groupe et qui fait tourner mon apache a accès a cette commande et tout va pour le mieux.

Le souci que j'ai maintenant est que chez OVH, quand en simple utilisateur je fais ./ifconfig en étant bien sur dans le répertoire sbin, j'ai ceci :

gecko64_AT_r22455:/sbin$ ./ifconfig
Warning: cannot open /proc/net/dev (Aucun fichier ou répertoire de ce type). Limited output.

Alors la quand je me rends dans le /proc/net/, je vois des liens symboliques qui partent sur différents trucs, enfin je m'y perds "un peu"...

r22455:/proc# ls -ila
total 4
1 dr-xr-xr-x 122 root root 0 avr 18 16:12 .
2 drwxr-xr-x 21 root root 4096 avr 10 16:04 ..
24833691 dr-x------ 7 root root 0 mai 3 04:44 1
25490899 dr-x------ 7 root root 0 mai 3 06:47 1007
25490900 dr-x------ 7 root root 0 mai 3 06:47 1053
25478982 dr-x------ 7 root root 0 mai 3 06:45 1065
25478983 dr-x------ 7 root root 0 mai 3 06:45 1067
25478984 dr-x------ 7 root root 0 mai 3 06:45 1068
25478985 dr-x------ 7 root root 0 mai 3 06:45 1069
25478986 dr-x------ 7 root root 0 mai 3 06:45 1070
25478987 dr-x------ 7 root root 0 mai 3 06:45 1071
25478988 dr-x------ 7 root root 0 mai 3 06:45 1072
25478989 dr-x------ 7 root root 0 mai 3 06:45 1073
25478990 dr-x------ 7 root root 0 mai 3 06:45 1074
25478991 dr-x------ 7 root root 0 mai 3 06:45 1079
25478992 dr-x------ 7 root root 0 mai 3 06:45 1080
25129476 dr-x------ 7 root root 0 mai 3 05:39 1081
25452092 dr-x------ 7 root root 0 mai 3 06:40 1129
25452093 dr-x------ 7 root root 0 mai 3 06:40 1131
25452094 dr-x------ 7 root root 0 mai 3 06:40 1132
25502824 dr-x------ 7 root root 0 mai 3 06:49 114
25452095 dr-x------ 7 root root 0 mai 3 06:40 1148
25532999 dr-x------ 7 root root 0 mai 3 06:55 115
25533000 dr-x------ 7 root root 0 mai 3 06:55 116
25533001 dr-x------ 7 root root 0 mai 3 06:55 117
25533002 dr-x------ 7 root root 0 mai 3 06:55 118
25533003 dr-x------ 7 root root 0 mai 3 06:55 119
25452096 dr-x------ 7 root root 0 mai 3 06:40 1251
25265072 dr-x------ 7 root root 0 mai 3 06:05 13361
25129827 dr-x------ 7 gecko64 gecko64 0 mai 3 05:39 13365
25238388 dr-x------ 7 gecko64 gecko64 0 mai 3 06:00 13367
25533004 dr-x------ 7 root root 0 mai 3 06:55 192
25129438 dr-x------ 7 root root 0 mai 3 05:39 193
25533446 dr-x------ 7 root root 0 mai 3 06:55 194
25533447 dr-x------ 7 root root 0 mai 3 06:55 195
24833692 dr-x------ 7 root root 0 mai 3 04:44 2
25533448 dr-x------ 7 root root 0 mai 3 06:55 200
25238389 dr-x------ 7 shoutcast utmp 0 mai 3 06:00 20066
25238390 dr-x------ 7 shoutcast shoutcast 0 mai 3 06:00 20067
25533449 dr-x------ 7 root root 0 mai 3 06:55 203
25129443 dr-x------ 7 root root 0 mai 3 05:39 252
25533615 dr-x------ 7 root root 0 mai 3 06:55 253
25533616 dr-x------ 7 root root 0 mai 3 06:55 254
25559775 dr-x------ 7 root root 0 mai 3 07:00 255
25452097 dr-x------ 7 root root 0 mai 3 06:40 2555
25559776 dr-x------ 7 root root 0 mai 3 07:00 256
25559777 dr-x------ 7 root root 0 mai 3 07:00 259
25491780 dr-x------ 7 root root 0 mai 3 06:47 260
25491781 dr-x------ 7 root root 0 mai 3 06:47 261
25491782 dr-x------ 7 root root 0 mai 3 06:47 263
25491783 dr-x------ 7 root root 0 mai 3 06:47 264
25559778 dr-x------ 7 root root 0 mai 3 07:00 265
25559779 dr-x------ 7 root root 0 mai 3 07:00 266 25491476 dr-x------ 7 root root 0 mai 3 06:47 267
25491477 dr-x------ 7 root root 0 mai 3 06:47 268
25491478 dr-x------ 7 root root 0 mai 3 06:47 269
25491479 dr-x------ 7 root root 0 mai 3 06:47 270
25238391 dr-x------ 7 shoutcast shoutcast 0 mai 3 06:00 27915
25129484 dr-x------ 7 root root 0 mai 3 05:39 2974
25425424 dr-x------ 7 messagebus messagebus 0 mai 3 06:35 2988
25129832 dr-x------ 7 www-data www-data 0 mai 3 05:39 29992
25211522 dr-x------ 7 www-data www-data 0 mai 3 05:55 29993
25211523 dr-x------ 7 www-data www-data 0 mai 3 05:55 29994
25211524 dr-x------ 7 www-data www-data 0 mai 3 05:55 29995
24833693 dr-x------ 7 root root 0 mai 3 04:44 3 25211526 dr-x------ 7 www-data www-data 0 mai 3 05:55 30115
24985445 dr-x------ 7 bind bind 0 mai 3 05:12 3030
25398807 dr-x------ 7 root root 0 mai 3 06:30 3046
25398808 dr-x------ 7 root root 0 mai 3 06:30 3214
25398809 dr-x------ 7 root root 0 mai 3 06:30 3215
25211527 dr-x------ 7 root root 0 mai 3 05:55 32279
25211528 dr-x------ 7 gecko64 gecko64 0 mai 3 05:55 32284
25211529 dr-x------ 7 gecko64 gecko64 0 mai 3 05:55 32285
25184930 dr-x------ 7 root root 0 mai 3 05:50 32298
25184931 dr-x------ 7 root root 0 mai 3 05:50 32299
25184932 dr-x------ 7 nobody nogroup 0 mai 3 05:50 32548
25184933 dr-x------ 7 manu manu 0 mai 3 05:50 32551
25184935 dr-x------ 7 www-data www-data 0 mai 3 05:50 32558
25398810 dr-x------ 7 Debian-exim Debian-exim 0 mai 3 06:30 3511
25398811 dr-x------ 7 root root 0 mai 3 06:30 3538
25129491 dr-x------ 7 root root 0 mai 3 05:39 3542
25372097 dr-x------ 7 root root 0 mai 3 06:25 3562
25372098 dr-x------ 7 root root 0 mai 3 06:25 3582
25129810 dr-x------ 7 gecko64 gecko64 0 mai 3 05:39 3597
25129811 dr-x------ 7 mumble-server mumble-server 0 mai 3 05:39 3725
25319190 dr-x------ 7 root root 0 mai 3 06:15 3768
25319191 dr-x------ 7 root root 0 mai 3 06:15 3769
25319192 dr-x------ 7 root root 0 mai 3 06:15 3770
25319193 dr-x------ 7 root root 0 mai 3 06:15 3771
25319194 dr-x------ 7 root root 0 mai 3 06:15 3772
25319195 dr-x------ 7 root root 0 mai 3 06:15 3773
25292341 dr-x------ 7 root root 0 mai 3 06:10 3774
25292342 dr-x------ 7 icecast2 icecast 0 mai 3 06:10 3804
25532735 dr-x------ 7 root root 0 mai 3 06:55 4
25292343 dr-x------ 7 root root 0 mai 3 06:10 4760
25532736 dr-x------ 7 root root 0 mai 3 06:55 5
25711347 dr-x------ 7 www-data www-data 0 mai 3 07:28 5864
25505964 dr-x------ 7 root root 0 mai 3 06:50 6
25860057 dr-x------ 7 www-data www-data 0 mai 3 07:56 6579
25860058 dr-x------ 7 www-data www-data 0 mai 3 07:56 6587
25506823 dr-x------ 7 root root 0 mai 3 06:50 7
25866267 dr-x------ 7 root root 0 mai 3 07:57 7069
25491480 dr-x------ 7 www-data www-data 0 mai 3 06:47 729
25532737 dr-x------ 7 root root 0 mai 3 06:55 8
25265666 dr-x------ 7 root root 0 mai 3 06:05 8210
25129822 dr-x------ 7 mysql mysql 0 mai 3 05:39 8249
25265069 dr-x------ 7 root root 0 mai 3 06:05 8250
25532998 dr-x------ 7 root root 0 mai 3 06:55 9
25129460 dr-x------ 7 root root 0 mai 3 05:39 973
25490897 dr-x------ 7 root root 0 mai 3 06:47 990
25490898 dr-x------ 7 root root 0 mai 3 06:47 992
4026531930 dr-xr-xr-x 6 root root 0 mai 3 07:57 acpi
4026531856 -r--r--r-- 1 root root 0 mai 3 07:57 buddyinfo
4026531872 dr-xr-xr-x 4 root root 0 mai 3 07:57 bus
4026531874 -r--r--r-- 1 root root 0 mai 3 07:57 cgroups
4026531845 -r--r--r-- 1 root root 0 mai 3 07:57 cmdline
4026531851 -r--r--r-- 1 root root 0 mai 3 07:57 cpuinfo
4026532007 -r--r--r-- 1 root root 0 mai 3 07:57 crypto
4026531850 -r--r--r-- 1 root root 0 mai 3 07:57 devices
4026531860 -r--r--r-- 1 root root 0 mai 3 07:57 diskstats
4026531968 -r--r--r-- 1 root root 0 mai 3 07:57 dma
4026531865 dr-xr-xr-x 2 root root 0 mai 3 07:57 driver
4026531846 -r--r--r-- 1 root root 0 mai 3 07:57 execdomains
4026531844 -r--r--r-- 1 root root 0 mai 3 07:57 filesystems
4026531864 dr-xr-xr-x 10 root root 0 mai 3 07:57 fs
4026532040 dr-xr-xr-x 3 root root 0 mai 3 07:57 ide
4026531854 -r--r--r-- 1 root root 0 mai 3 07:57 interrupts
4026531966 -r--r--r-- 1 root root 0 mai 3 07:57 iomem
4026531965 -r--r--r-- 1 root root 0 mai 3 07:57 ioports
4026531875 dr-xr-xr-x 22 root root 0 mai 3 07:57 irq
4026531969 -r--r--r-- 1 root root 0 mai 3 07:57 kallsyms
4026531848 -r-------- 1 root root 0 mai 3 03:22 kmsg
4026531840 -r--r--r-- 1 root root 0 mai 3 07:57 loadavg
4026531849 -r--r--r-- 1 root root 0 mai 3 07:57 locks
4026531940 -r--r--r-- 1 root root 0 avr 18 16:13 mdstat
4026531842 -r--r--r-- 1 root root 0 mai 3 07:57 meminfo
4026531933 -r--r--r-- 1 root root 0 mai 3 07:57 misc
4026531847 lrwxrwxrwx 1 root root 11 mai 3 07:57 mounts -> self/mounts
4026532051 dr-xr-xr-x 2 root root 0 mai 3 07:57 mpt
4026532054 -r--r--r-- 1 root root 0 mai 3 07:57 mtd
4026531861 lrwxrwxrwx 1 root root 8 mai 3 07:57 net -> self/net
4026531857 -r--r--r-- 1 root root 0 mai 3 07:57 pagetypeinfo
4026531852 -r--r--r-- 1 root root 0 mai 3 07:57 partitions
4026531934 dr-xr-xr-x 2 root root 0 mai 3 07:57 scsi
25158010 lrwxrwxrwx 1 root root 64 mai 3 05:45 self -> 7069
4026531853 -r--r--r-- 1 root root 0 mai 3 07:57 stat
4026531970 -r--r--r-- 1 root root 0 mai 3 07:57 swaps
4026531873 dr-xr-xr-x 1 root root 0 mai 3 06:50 sys
4026531863 dr-xr-xr-x 2 root root 0 mai 3 07:57 sysvipc
4026531967 -rw-r--r-- 1 root root 0 mai 3 07:57 timer_list
4026531867 dr-xr-xr-x 4 root root 0 mai 3 07:57 tty
4026531841 -r--r--r-- 1 root root 0 mai 3 07:57 uptime
4026531843 -r--r--r-- 1 root root 0 mai 3 07:57 version
4026531855 -r-------- 1 root root 0 mai 3 07:57 vmallocinfo
4026531858 -r--r--r-- 1 root root 0 mai 3 07:57 vmstat
4026531859 -r--r--r-- 1 root root 0 mai 3 07:57 zoneinfo

Si quelqu'un a une idée sur la question pour résoudre mon souci? :)

Merci :)

Lien vers le commentaire
Partager sur d’autres sites

Hello,

OVH utilise des kernels avec le patch GRSEC qui désactive l'accès à plusieurs trucs du genre, ça ne m'étonnerait pas que ce soit lui qui bloque cela. Pour ma part je le vire car je préfère avoir des outils de monitoring opérationnels et un kernel suivi par Debian (ou par moi) plutôt que celui d'OVH ; mais je te laisse faire ton choix.

En tous cas grâce au netboot tu peux "facilement" tester avec un autre kernel pour voir si cela vient bien de cela (attention de prendre le bon).

Lien vers le commentaire
Partager sur d’autres sites

Ha ok merci :)

Je ne connaissais pas le nom de ce module la.

Je ferai quelques tests de mon côté car je n'ai jamais vraiment personnalisé mon Kernel :P

Le seul que j'avais compilé il y a bien 4 ans m'avait fait un plantage au boot ^^

Depuis, ca me fait un peu peur surtout que cette machine est en production :P

Lien vers le commentaire
Partager sur d’autres sites

Veuillez vous connecter pour commenter

Vous pourrez laisser un commentaire après vous êtes connecté.



Connectez-vous maintenant
×
×
  • Créer...