This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #!/bin/bash | |
| # Functions | |
| doBind(){ | |
| echo "Attempting AD bind" | |
| ntpdate -u ad.domain.fqdn | |
| dsconfigad -a "$(scutil --get ComputerName | cut -c1-15) -u $bindServiveAccount -p "$password" -localhome anable -useundpath disable -alldomains enable -groups "$adminGroupHere" -mobile enable -mobildconfirm disable -doman ad.domain.fqdn -force -passinterval 0 -ou "OU=Path,OU=To,OU=OU,OU=In,DC=ad,DC=domain,DC=fqdn" | |
| } | |
| # Remove existing object to remove bind conflicts on local machine |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #include <iostream> | |
| #include <fstream> | |
| using namespace std; | |
| int main() | |
| { | |
| //Declare Variables | |
| int startPort = 0; | |
| int endPort = 0; | |
| size_t numSets; |