Exemple #1
0
    def atom(self, host):
        import bsd
        import linux
        import mac
        import solaris
        import unix
        import windows
        import urllib
        from core.urli import sansor
        host = sansor().fransor(host)
        hostp = sansor().pransor(host)
        if sansor().cransor(hostp):
            header = urllib.urlopen(host).headers
            final = []
            bsd = bsd.Bsd().run(header)
            lnx = linux.Linux().run(header)
            mac = mac.Mac().run(header)
            slr = solaris.Solaris().run(header)
            unx = unix.Unix().run(header)
            win = windows.Windows().run(header)

            eve = [bsd, lnx, mac, slr, unx, win]
            for key in eve:
                if key:
                    final.append(key)
            if final == []:
                final.append('none')
            return final
        else:
            return None
Exemple #2
0
def Os(headers):
	return (
		bsd.Bsd().run(headers),
		windows.Windows().run(headers),
		linux.Linux().run(headers),
		solaris.Solaris().run(headers),
		unix.Unix().run(headers),
		mac.Mac().run(headers)
		)
Exemple #3
0
 def __init__(self, env, name, ether, latitude, longitude, stats):
     self.env = env
     self.name = name
     self.ether = ether
     self.latitude = latitude
     self.longitude = longitude
     self.stats = stats
     self.mac = mac.Mac(self)
     print('%s created with coordinates %d %d' %
           (self.name, self.latitude, self.longitude))