IPsec tunnel to Azure won't connect [SOLVED]

I want to create a S2S IPSec tunnel to Azure, so I followed this guide and this guide, but both don’t get a succesful connection. And from the logs I can’t find (or understand) the (direction) of the problem. I hope someone here can help.

Here’s an export from my full config:

# mar/05/2020 12:25:02 by RouterOS 6.40.4
# software id = 6I9F-HF4C
#
# model = 960PGS
# serial number = 89F908B7228C
/interface bridge
add admin-mac=CC:2D:E0:67:F6:BD auto-mac=no comment=defconf name=bridge
/interface ethernet
set [ find default-name=ether1 ] comment=WAN
set [ find default-name=ether2 ] comment=LAN name=ether2-master
set [ find default-name=ether3 ] disabled=yes master-port=ether2-master
set [ find default-name=ether4 ] disabled=yes master-port=ether2-master
set [ find default-name=ether5 ] disabled=yes master-port=ether2-master
set [ find default-name=sfp1 ] disabled=yes
/ip neighbor discovery
set ether1 discover=no
/interface list
add comment=defconf name=WAN
add comment=defconf name=LAN
/interface wireless security-profiles
set [ find default=yes ] supplicant-identity=MikroTik
/ip hotspot profile
set [ find default=yes ] html-directory=flash/hotspot
/ip ipsec proposal
add auth-algorithms=sha256 enc-algorithms=aes-256-cbc,aes-128-cbc lifetime=\
    7h30m name=azure-ipsec-proposal
/ip pool
add name=VPN ranges=192.168.3.50-192.168.3.70
/ip dhcp-server
add address-pool=VPN interface=bridge name=defconf
/ppp profile
add dns-server=192.168.2.20 local-address=192.168.2.254 name=VPN \
    remote-address=VPN use-encryption=required
/interface bridge port
add bridge=bridge comment=defconf interface=ether2-master
add bridge=bridge comment=defconf interface=sfp1
/interface list member
add comment=defconf interface=bridge list=LAN
add comment=defconf interface=ether1 list=WAN
/interface sstp-server server
set authentication=mschap2 certificate=Server default-profile=VPN enabled=yes \
    force-aes=yes pfs=yes tls-version=only-1.2
/ip address
add address=192.168.2.254/24 comment="defconf - LAN" interface=ether2-master \
    network=192.168.2.0
add address=192.168.178.2/24 comment=WAN interface=ether1 network=192.168.178.0
/ip dhcp-client
add comment=defconf dhcp-options=hostname,clientid interface=ether1
/ip dhcp-server network
add address=192.168.2.0/24 comment=defconf gateway=192.168.2.254 netmask=24
/ip dns
set allow-remote-requests=yes servers=192.168.2.20
/ip dns static
add address=192.168.88.1 name=router.lan
/ip firewall address-list
add address=0.0.0.0/8 comment=RFC6890 list=NotPublic
add address=10.0.0.0/8 comment=RFC6890 list=NotPublic
add address=100.64.0.0/10 comment=RFC6890 list=NotPublic
add address=127.0.0.0/8 comment=RFC6890 list=NotPublic
add address=169.254.0.0/16 comment=RFC6890 list=NotPublic
add address=172.16.0.0/12 comment=RFC6890 list=NotPublic
add address=192.0.0.0/24 comment=RFC6890 list=NotPublic
add address=192.0.2.0/24 comment=RFC6890 list=NotPublic
add address=192.168.0.0/16 comment=RFC6890 list=NotPublic
add address=192.88.99.0/24 comment=RFC3068 list=NotPublic
add address=198.18.0.0/15 comment=RFC6890 list=NotPublic
add address=198.51.100.0/24 comment=RFC6890 list=NotPublic
add address=203.0.113.0/24 comment=RFC6890 list=NotPublic
add address=224.0.0.0/4 comment=RFC4601 list=NotPublic
add address=240.0.0.0/4 comment=RFC6890 list=NotPublic
/ip firewall filter
add action=accept chain=input comment=\
    "defconf: accept established,related,untracked" connection-state=\
    established,related,untracked
add action=drop chain=input comment="defconf: drop invalid" connection-state=\
    invalid
add action=accept chain=input comment="defconf: accept ICMP" protocol=icmp
add action=accept chain=input comment="Allow SSTP VPN" dst-port=443 protocol=\
    tcp
add action=accept chain=input comment="Allow VPN subnet traffic to the router" \
    src-address=192.168.3.0/24
add action=accept chain=input comment=\
    "Allow Azure subnet traffic to the router" log=yes src-address=\
    172.16.0.0/20
add action=accept chain=forward comment=\
    "Allow VPN subnet traffic through the router" src-address=192.168.3.0/24
add action=accept chain=forward comment=\
    "Allow Azure subnet traffic through the router" log=yes src-address=\
    172.16.0.0/20
add action=drop chain=input comment="defconf: drop all not coming from LAN" \
    in-interface-list=!LAN
add action=accept chain=forward comment="defconf: accept in ipsec policy" \
    ipsec-policy=in,ipsec log=yes
add action=accept chain=forward comment="defconf: accept out ipsec policy" \
    ipsec-policy=out,ipsec log=yes
add action=fasttrack-connection chain=forward comment="defconf: fasttrack" \
    connection-state=established,related
add action=accept chain=forward comment=\
    "defconf: accept established,related, untracked" connection-state=\
    established,related,untracked
add action=drop chain=forward comment="defconf: drop invalid" connection-state=\
    invalid
add action=drop chain=forward comment=\
    "defconf:  drop all from WAN not DSTNATed" connection-nat-state=!dstnat \
    connection-state=new in-interface-list=WAN
/ip firewall mangle
add action=change-mss chain=forward new-mss=1350 passthrough=yes protocol=tcp \
    tcp-flags=syn tcp-mss=!0-1350
/ip firewall nat
add action=accept chain=srcnat comment=Azure dst-address=172.16.0.0/20 log=yes \
    src-address=192.168.2.0/24
add action=masquerade chain=srcnat comment="defconf: masquerade" ipsec-policy=\
    out,none out-interface-list=WAN
add action=masquerade chain=srcnat comment="Allow internet from VPN" \
    src-address=192.168.3.0/24
add action=masquerade chain=srcnat comment="Allow Plex" dst-address=\
    192.168.2.18 dst-port=32400 out-interface=ether1 protocol=tcp
/ip ipsec peer
add address=51.az.ure.ip/32 comment=Azure dh-group=modp1024 enc-algorithm=\
    aes-256 exchange-mode=ike2 hash-algorithm=sha256 lifetime=8h
/ip ipsec policy
add comment=Azure dst-address=172.16.0.0/20 proposal=azure-ipsec-proposal \
    sa-dst-address=51.az.ure.ip sa-src-address=92.ho.me.ip src-address=\
    192.168.2.0/24 tunnel=yes
/ip route
add check-gateway=ping comment=WAN distance=1 gateway=192.168.178.1
/ip service
set telnet disabled=yes
set ftp disabled=yes
set ssh disabled=yes
set api disabled=yes
set winbox disabled=yes
set api-ssl disabled=yes
/ppp secret
add name=USERNAME profile=VPN service=sstp
/system clock
set time-zone-name=Europe/Amsterdam
/system identity
set name=mikrotik_router
/system logging
set 0 disabled=yes
add topics=firewall
add topics=interface
add topics=route
add topics=ipsec
/tool mac-server
set [ find default=yes ] disabled=yes
add interface=bridge
/tool mac-server mac-winbox
set [ find default=yes ] disabled=yes
add interface=bridge
[adminuser@mikrotik] > /

And here’s a log file (can’t get a second codeblock to work).

edit: I forgot to add that I have added the firewall policies mentioned in this post, but that doesn’t help.

Thanks to u/mintlou on on Reddit upgraded my RouterOS to the latest (4.46), and set my IPsec profile to the settings he mentioned.
For future reference, below is my IPSec & firewall incl. NAT config:
IPSec

# mar/06/2020 09:07:08 by RouterOS 6.46.4
# software id = 6I9F-HF4C
#
# model = 960PGS
# serial number = 89F908B7228C
/ip ipsec profile
add dh-group=modp1024 enc-algorithm=aes-256,aes-128 lifetime=8h name=Azure
/ip ipsec peer
add address=51.azu.re.ip/32 comment=Azure exchange-mode=ike2 name=Azure \
    profile=Azure
/ip ipsec proposal
add auth-algorithms=sha256,sha1 enc-algorithms=aes-256-cbc,aes-128-cbc \
    lifetime=7h30m name=azure-ipsec-proposal
/ip ipsec identity
add peer=Azure secret=[secret]
/ip ipsec policy
set 0 disabled=yes
add comment=Azure dst-address=172.16.0.0/20 peer=Azure proposal=\
    azure-ipsec-proposal sa-dst-address=51.azu.re.ip sa-src-address=0.0.0.0 \
    src-address=192.168.2.0/24 tunnel=yes

Firewall

# mar/06/2020 09:08:04 by RouterOS 6.46.4
# software id = 6I9F-HF4C
#
# model = 960PGS
# serial number = 89F908B7228C
/ip firewall address-list
add address=0.0.0.0/8 comment=RFC6890 list=NotPublic
add address=10.0.0.0/8 comment=RFC6890 list=NotPublic
add address=100.64.0.0/10 comment=RFC6890 list=NotPublic
add address=127.0.0.0/8 comment=RFC6890 list=NotPublic
add address=169.254.0.0/16 comment=RFC6890 list=NotPublic
add address=172.16.0.0/12 comment=RFC6890 list=NotPublic
add address=192.0.0.0/24 comment=RFC6890 list=NotPublic
add address=192.0.2.0/24 comment=RFC6890 list=NotPublic
add address=192.168.0.0/16 comment=RFC6890 list=NotPublic
add address=192.88.99.0/24 comment=RFC3068 list=NotPublic
add address=198.18.0.0/15 comment=RFC6890 list=NotPublic
add address=198.51.100.0/24 comment=RFC6890 list=NotPublic
add address=203.0.113.0/24 comment=RFC6890 list=NotPublic
add address=224.0.0.0/4 comment=RFC4601 list=NotPublic
add address=240.0.0.0/4 comment=RFC6890 list=NotPublic
/ip firewall filter
add action=accept chain=input comment=\
    "defconf: accept established,related,untracked" connection-state=\
    established,related,untracked
add action=drop chain=input comment="defconf: drop invalid" connection-state=\
    invalid
add action=accept chain=input comment="defconf: accept ICMP" protocol=icmp
add action=accept chain=input comment="Allow SSTP VPN" dst-port=443 protocol=\
    tcp
add action=accept chain=input comment=\
    "Allow VPN subnet traffic to the router" src-address=192.168.3.0/24
add action=accept chain=input comment=\
    "Allow Azure subnet traffic to the router" log=yes src-address=\
    172.16.0.0/20
add action=accept chain=forward comment=\
    "Allow VPN subnet traffic through the router" src-address=192.168.3.0/24
add action=accept chain=forward comment=\
    "Allow Azure subnet traffic through the router" log=yes src-address=\
    172.16.0.0/20
add action=drop chain=input comment="defconf: drop all not coming from LAN" \
    in-interface-list=!LAN
add action=accept chain=forward comment="defconf: accept in ipsec policy" \
    ipsec-policy=in,ipsec log=yes
add action=accept chain=forward comment="defconf: accept out ipsec policy" \
    ipsec-policy=out,ipsec log=yes
add action=fasttrack-connection chain=forward comment="defconf: fasttrack" \
    connection-state=established,related
add action=accept chain=forward comment=\
    "defconf: accept established,related, untracked" connection-state=\
    established,related,untracked
add action=drop chain=forward comment="defconf: drop invalid" \
    connection-state=invalid
add action=drop chain=forward comment=\
    "defconf:  drop all from WAN not DSTNATed" connection-nat-state=!dstnat \
    connection-state=new in-interface-list=WAN
/ip firewall mangle
add action=change-mss chain=forward log=yes new-mss=1350 passthrough=yes \
    protocol=tcp tcp-flags=syn tcp-mss=!0-1350
/ip firewall nat
add action=accept chain=srcnat comment=Azure dst-address=172.16.0.0/20 log=\
    yes src-address=192.168.2.0/24
add action=masquerade chain=srcnat comment="defconf: masquerade" \
    ipsec-policy=out,none out-interface-list=WAN
add action=masquerade chain=srcnat comment="Allow internet from VPN" \
    src-address=192.168.3.0/24
add action=masquerade chain=srcnat comment="Allow Plex" dst-address=\
    192.168.2.x dst-port=32400 out-interface=ether1 protocol=tcp