Commit 159d059
ksmbd: fix out-of-bounds in parse_sec_desc()
commit d6e13e1 upstream.
If osidoffset, gsidoffset and dacloffset could be greater than smb_ntsd
struct size. If it is smaller, It could cause slab-out-of-bounds.
And when validating sid, It need to check it included subauth array size.
Cc: [email protected]
Reported-by: Norbert Szetei <[email protected]>
Tested-by: Norbert Szetei <[email protected]>
Signed-off-by: Namjae Jeon <[email protected]>
Signed-off-by: Steve French <[email protected]>
Signed-off-by: Greg Kroah-Hartman <[email protected]>1 parent 3cb2b2e commit 159d059
1 file changed
+16
-0
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
807 | 807 | | |
808 | 808 | | |
809 | 809 | | |
| 810 | + | |
| 811 | + | |
| 812 | + | |
| 813 | + | |
| 814 | + | |
| 815 | + | |
| 816 | + | |
810 | 817 | | |
811 | 818 | | |
812 | 819 | | |
| |||
848 | 855 | | |
849 | 856 | | |
850 | 857 | | |
| 858 | + | |
| 859 | + | |
| 860 | + | |
851 | 861 | | |
852 | 862 | | |
853 | 863 | | |
| |||
863 | 873 | | |
864 | 874 | | |
865 | 875 | | |
| 876 | + | |
| 877 | + | |
| 878 | + | |
866 | 879 | | |
867 | 880 | | |
868 | 881 | | |
| |||
884 | 897 | | |
885 | 898 | | |
886 | 899 | | |
| 900 | + | |
| 901 | + | |
| 902 | + | |
887 | 903 | | |
888 | 904 | | |
889 | 905 | | |
| |||
0 commit comments