top of page
tixekadedican

Winexe On Centos Linux: A Step-By-Step Guide



Winexe is a GNU/Linux based application that allows users to execute commands remotely on WindowsNT/2000/XP/2003/Vista/7/8 systems. It installs a service on the remote system, executes the command and uninstalls the service. Winexe allows execution of most of the windows shell commands.How to install:You can download the source package from here [Current version is winexe-1.00.tar.gz]


this will create a [ winexe ] binary file in the bin folder. You can use that binary to execute the windows commands from Linux.or else there are some compiled version of binary itself available for download. You can download and use it from here.The above version of winexe works only till version Windows Server 2012. For Windows Server 2012R2 requires below method to make winexe work with latest version of windows. Below method will get the code for samba and winexe from the github repository and we will have to build it for it to work.Alternate Method (Best Method to Work with Latest Version of Windows 10 and Windows Server 2012R2) -1-1-centos-6-and-windows-2012-r2/




How To Install Winexe On Centos Linux



[root@centos6 ]# yum install wmiLoaded plugins: fastestmirror, refresh-packagekitSetting up Install ProcessLoading mirror speeds from cached hostfile * atomic: mirror1.34sp.com * base: mirror.steadfast.net * centosplus: mirror.steadfast.net * contrib: mirror.steadfast.net * epel: mirror.ibcp.fr * extras: mirror.steadfast.net * updates: mirror.steadfast.netPackage wmi is obsoleted by openvas-smb, trying to install openvas-smb-1.0.1-1.el6.art.x86_64 insteadResolving Dependencies--> Running transaction check---> Package openvas-smb.x86_64 0:1.0.1-1.el6.art will be installed--> Processing Dependency: libroken.so.18(HEIMDAL_ROKEN_1.0)(64bit) for package: openvas-smb-1.0.1-1.el6.art.x86_64--> Processing Dependency: libkrb5.so.26(HEIMDAL_KRB5_2.0)(64bit) for package: openvas-smb-1.0.1-1.el6.art.x86_64--> Processing Dependency: libhdb.so.9(HEIMDAL_HDB_1.0)(64bit) for package: openvas-smb-1.0.1-1.el6.art.x86_64--> Processing Dependency: libgssapi.so.3(HEIMDAL_GSS_2.0)(64bit) for package: openvas-smb-1.0.1-1.el6.art.x86_64--> Processing Dependency: libgnutls.so.28(GNUTLS_1_4)(64bit) for package: openvas-smb-1.0.1-1.el6.art.x86_64--> Processing Dependency: libasn1.so.8(HEIMDAL_ASN1_1.0)(64bit) for package: openvas-smb-1.0.1-1.el6.art.x86_64--> Processing Dependency: atomic-gnutls3-gnutls for package: openvas-smb-1.0.1-1.el6.art.x86_64--> Processing Dependency: atomic-glib2-glib2 for package: openvas-smb-1.0.1-1.el6.art.x86_64--> Processing Dependency: libwind.so.0()(64bit) for package: openvas-smb-1.0.1-1.el6.art.x86_64--> Processing Dependency: libroken.so.18()(64bit) for package: openvas-smb-1.0.1-1.el6.art.x86_64--> Processing Dependency: libkrb5.so.26()(64bit) for package: openvas-smb-1.0.1-1.el6.art.x86_64--> Processing Dependency: libhx509.so.5()(64bit) for package: openvas-smb-1.0.1-1.el6.art.x86_64--> Processing Dependency: libheimntlm.so.0()(64bit) for package: openvas-smb-1.0.1-1.el6.art.x86_64--> Processing Dependency: libhdb.so.9()(64bit) for package: openvas-smb-1.0.1-1.el6.art.x86_64--> Processing Dependency: libhcrypto.so.4()(64bit) for package: openvas-smb-1.0.1-1.el6.art.x86_64--> Processing Dependency: libgssapi.so.3()(64bit) for package: openvas-smb-1.0.1-1.el6.art.x86_64--> Processing Dependency: libgnutls.so.28()(64bit) for package: openvas-smb-1.0.1-1.el6.art.x86_64--> Processing Dependency: libasn1.so.8()(64bit) for package: openvas-smb-1.0.1-1.el6.art.x86_64--> Running transaction check---> Package atomic-glib2-glib2.x86_64 0:2.41.0-2.el6.art will be installed---> Package atomic-gnutls3-gnutls.x86_64 1:3.1.25-1.el6.art will be installed--> Processing Dependency: libnettle.so.4()(64bit) for package: 1:atomic-gnutls3-gnutls-3.1.25-1.el6.art.x86_64--> Processing Dependency: libhogweed.so.2()(64bit) for package: 1:atomic-gnutls3-gnutls-3.1.25-1.el6.art.x86_64---> Package heimdal-libs.x86_64 0:1.6.0-0.9.20140621gita5adc06.el6 will be installed--> Running transaction check---> Package nettle.x86_64 0:2.7.1-3.el6.art will be installed--> Finished Dependency Resolution


root@centos6 ]# winexe -A credentials.cfg //192.168.123.13 'cmd.exe /c echo "hello"'"hello"You have mail in /var/spool/mail/root[root@centos6 ]# winexe -A credentials.cfg //192.168.123.13 'hostname'DWAUGH03


The first step is to install the proper version of Powershell. In order for this to work, you need to have a newer version of Powershell installed. As of writing this post, the current version on which this works is 6.2.3. The reason for this is that its a relatively new feature for linux powershell. 2ff7e9595c


1 view0 comments

Recent Posts

See All

Sofascore apk

APK do Sofascore: o melhor aplicativo de esportes para resultados e estatísticas ao vivo Se você é um fã de esportes, provavelmente...

Comments


bottom of page