current-local-map

current-local-map is a built-in function in `C source code'.

(current-local-map)

Return current buffer's local keymap, or nil if it has none.
Normally the local keymap is set by the major mode with `use-local-map'.