Skocz do zawartości

MizderCrack

Użytkownicy
  • Zawartość

    5
  • Rejestracja

  • Ostatnio

Reputacja

0 Normalna

1 obserwujący

O MizderCrack

  • Ranga
    Nowy użytkownik
  1. [PHP][SSH] Skrypt wykonujący komendy ssh w php

    @up niestety nie ale już sobie poradziłem z tym problemem. Oto kod jak by ktoś potrzebował: <? $con = ssh2_connect("localhost", 22); ssh2_auth_password($con, "login", "haslo"); $stream = ssh2_shell($con, 'vt102', null, 80, 24, SSH2_TERM_UNIT_CHARS); fwrite( $stream, 'screen -r 5005'.PHP_EOL); if(isset($_POST['slij'])) { $komeda = $_POST['command']; fwrite($stream, $komeda.PHP_EOL); } sleep(1); while($line = fgets($stream)) { flush(); $data .= $line."<br />"; } ?> Można zamknąć
  2. [PHP][SSH] Skrypt wykonujący komendy ssh w php

    @Archi Nie za bardzo rozumiem o co ci chodzi mógłbyś powiedzieć trochę jaśniej??? @linoskoczek Niestety ale bez tego nic się nie wyświetla, poza tym nawet w dokumentacji ssh2 piszą żeby tego używać. Ech ma ktoś jakieś inne pomysły??
  3. [PHP][SSH] Skrypt wykonujący komendy ssh w php

    nadal to samo... Jakieś inne pomysły?? EDIT: Czy ma ktoś gotowy skrypt konsoli serwerowej z jakiejś gry która by się łączyła za pomocą ssh???
  4. [PHP][SSH] Skrypt wykonujący komendy ssh w php

    W odpowiedzi dostałem: Usage: java [-options] class [args...] (to execute a class) or java [-options] -jar jarfile [args...] (to execute a jar file) where options include: -d32 use a 32-bit data model if available -d64 use a 64-bit data model if available -client to select the "client" VM -server to select the "server" VM -jamvm to select the "jamvm" VM -cacao to select the "cacao" VM -zero to select the "zero" VM -hotspot is a synonym for the "client" VM [deprecated] The default VM is client. -cp <class search path of directories and zip/jar files> -classpath <class search path of directories and zip/jar files> A : separated list of directories, JAR archives, and ZIP archives to search for class files. -D<name>=<value> set a system property -verbose[:class|gc|jni] enable verbose output -version print product version and exit -version:<value> require the specified version to run -showversion print product version and continue -jre-restrict-search | -jre-no-restrict-search include/exclude user private JREs in the version search -? -help print this help message -X print help on non-standard options -ea[:<packagename>...|:<classname>] -enableassertions[:<packagename>...|:<classname>] enable assertions with specified granularity -da[:<packagename>...|:<classname>] -disableassertions[:<packagename>...|:<classname>] disable assertions with specified granularity -esa | -enablesystemassertions enable system assertions -dsa | -disablesystemassertions disable system assertions -agentlib:<libname>[=<options>] load native agent library <libname>, e.g. -agentlib:hprof see also, -agentlib:jdwp=help and -agentlib:hprof=help -agentpath:<pathname>[=<options>] load native agent library by full pathname -javaagent:<jarpath>[=<options>] load Java programming language agent, see java.lang.instrument -splash:<imagepath> show splash screen with specified image See http://java.sun.com/javase/reference for more details.
  5. Witam od paru dni staram się napisać konsolę serwerową do pewnej gry (nie będę robił reklamy ) działającej w javie. Problem polega na tym że skrypt nie wyświetla zwróconych informacji, za to wyniki komendy ls -all normalnie wyświetla. Czy ktoś wie jak to naprawić?? Oto skrypt konsoli: <style type="text/css">#console {background-color: black;color: white;width: 650px;height: 300px;overflow: auto;}</style><?php$con = ssh2_connect("localhost", 22);ssh2_auth_password($con, "minecraft", "minecraft");$stream = ssh2_exec($con, "java" ); sleep(5); stream_set_blocking($stream, true); while ($buf = fread($stream, 1024)) {$data .= $buf;}fclose($stream);$data = str_replace("", "</br>", $data);?><div id="console"><?echo $data;?></div>
×