Kashyk was a Devore inspector and a member of the Devore Imperium in the 2370s. The Devore considered telepaths a danger to the Imperium because of their ability to read minds. Kashyk considered all strangers and vessels in Devore space to be suspect and subject to search. The Devore were looking for Brenari in particular.
Three months prior to Voyager's entrance into Devore space, Kashyk supposedly had a crisis in faith in his job after he was thanked by a Brenari child he found being smuggled in an extraction tank with her family. She was in there for days, barely able to breathe, and he had to send her to a relocation center afterward, which he claimed caused him to question his people's reasons for fearing telepaths before reasserting his belief that they were a danger to the Imperium and that his job was necessary.
USS Voyager had rescued a group of telepaths and was hiding them from the Devore. Kashyk was captain of the Devore starship that was inspecting Voyager at regular intervals. Kashyk inspected Voyager so many times that he became familiar with the crew and Voyager's musical database, and made himself at home in Captain Janeway's ready room. Tchaikovsky was his favorite Earth composer and he played his Symphony Number Four over the ship-wide comm.
In a plan to uncover telepaths on the Federation vessel, Kashyk asked for asylum on Voyager. Kashyk aided Janeway in avoiding Devore detection, and gave her information on the Devore systems. He tried to gain Janeway's trust by becoming romantically involved with her and pretending to be her ally. He was able to determine that Voyager was smuggling telepaths and Janeway was going to transport them through a wormhole to escape the Devore. He suggested that Janeway apply a fractal coefficient to Torat's sensor data, among other standard algorithms, to find the spatial anomaly, and understood the Captain's subspace harmonics analysis. When he found out its precise position, he announced to Janeway that he doubled-crossed her and fired on the wormhole; however, Janeway had never trusted him, and misled him into firing on a false wormhole. Janeway was able to transport the telepaths through the real wormhole. Kashyk, not wanting the failure on his record, and still harboring feelings for Janeway, failed to report the incident and allowed Voyager to resume its course. (VOY: "Counterpoint")