Mikrotik L2TP / IPsec VPN Server Step by Step configuration

August 29, 2024 |

 

Ref: 

https://www.cloudhosting.lv/eng/faq/Mikrotik-L2TP-IPsec-VPN-Server-Step-by-Step-configuration

How to enable VPN Server in Mikrotik Router

Step 1: PPP > Interface > L2TP Server


Check Enable & Enter IPSec Secret


Step 2: IP> Pool > Add

Make VPN Pool

Enter Name: VPN
Address      : 192.168.10.100-192.168.10.150

Step 3: PPP > Profile



- Make profile


- Enter Name       : VPN
- Local Addresss  : VPN-Pool
- Remote Address: VPN-Pool

- Rate Limit: 20M/20M

Step 4: PPP > Secret > Add




Enter Name        : test
Password            : 12356
Profile                : VPN
Local Address    : 192.168.10.100
Remote Address    : 192.168.10.101

Step 5: Firewall > Filter Rule (Important step)

- Allow port: 1701, 500, 4500
- Chain: input
- Protocol: udp
- Dst Port: 1701, 500, 4500
- Action: Accept



add more:



Final Result:


These rule must be on top another rules.

If you have any question, please send to me: hoquoctri@live.com

Thanks;





Read more…

MacOS A->Z

August 27, 2024 |

 



1. Install HomeBrew
Ref: https://brew.sh/

$ /bin/bash -c "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/HEAD/install.sh)"

If MacOS can't found brew command
$ echo "export PATH=/opt/homebrew/bin:$PATH" >> ~/.zshrc

2. Install NVM (Node Version Management)
You can install vary node version in PC and easy switch between node version

$ brew install nvm
$ nvm --version
$ nvm install --lts // Install Node latest version
$ nvm install <node_version>
$ nvm use <node version>

Note: if nvm command not found, add line below to ./zshrc

source $(brew --prefix nvm)/nvm.sh

3. Install Yarn command

$ brew install yarn

4. How to show NPM Scripts in Visual Studio Code

Go to View > Open View > Select NPM Script

5. Install Many Java Verison in Mac OS

$ /usr/libexec/java_home -V // All Java Installed will show here 












Read more…

React Native on WearOS

August 26, 2024 |

 


Ref:

https://github.com/fabOnReact/react-native-wear-connectivity?tab=readme-ov-file

I. Create React Native Project on Android

#Remove previous cli
$ npm uninstall -g react-native-cli @react-native-community/cli

#Init project
npx @react-native-community/cli@latest init AwesomeProject

#Edit package.json; Run on Default Port 8081 & Select Device 


#Create Android Simulator

# In Android Simulator > Install Google Watch App/Wear OS App
#Paire Wear Devices


- Must open Google Watch app while pair devices and init set up.

- Code in App.tsx




II. Create React Native Project on WearOS

#Remove previous cli
$ npm uninstall -g react-native-cli @react-native-community/cli

#Init project
npx @react-native-community/cli@latest init AwesomeProject

#Edit package.json , Run on Port 8082 & Select Device 


# Create Wear OS Simulator



- Code in App.tsx





Try test app:

Wear Device:


Android device display Alert from Wear Device:






















Read more…